'Run the edit command during an import session, with mocked stdin and
yaml writing.'

def run_mocked_interpreter(self, modify_file_args={}, stdin=[]):

    m = ModifyFileMocker(**modify_file_args)
    with patch('beetsplug.edit.edit', side_effect=m.action):
        with control_stdin('\n'.join(stdin)):
            self.importer.run()
