def test_get_notebook_writes_log_and_kills_proc_on_error( self, kill, logger, init_notebook): init_notebook.side_effect = platform_persistence.NotebookManagementError( 'err') notebook_config.get_notebook('path') logger.error.assert_called_with('err') logger.warn.assert_called_with(ANY) kill.assert_called_with(ANY, ANY)
def test_get_notebook_initializes_and_saves(self, post_save, init_notebook): notebook_config.get_notebook('path') init_notebook.assert_called_with('path') post_save.assert_called_with(ANY, 'path', None)