def test_run(self):
        obs = self.cmd(author='bob', email='bob@bob.bob',
                       license='very permissive license',
                       copyright='what\'s that?', version='1.0')
        self.assertEqual(list(obs.keys()), ['result'])

        obs = obs['result']
        self.assertEqual('\n'.join(obs), exp_header1)

        # With credits.
        obs = self.cmd(author='bob', email='bob@bob.bob',
                       license='very permissive license',
                       copyright='what\'s that?', version='1.0',
                       credits=['another person', 'another another person'])
        self.assertEqual(list(obs.keys()), ['result'])

        obs = obs['result']
        self.assertEqual('\n'.join(obs), exp_header2)

        # With no arguments
        obs = self.cmd()
        self.assertEqual(list(obs.keys()), ['result'])

        obs = obs['result']
        self.assertEqual('\n'.join(obs), exp_header3)
Correctly generates header with and without credits.
dataset/ETHPy150Open biocore/pyqi/tests/test_commands/test_code_header_generator.py/CodeHeaderGeneratorTests.test_run