def test_parse_options_version_only(self, stdout): cmd = Command() with self.assertRaises(SystemExit): cmd.parse_options('prog', ['--version']) stdout.write.assert_called_with(cmd.version + '\n')
def test_parse_options_version_only(self, stdout): cmd = Command() with self.assertRaises(SystemExit): cmd.parse_options("prog", ["--version"]) stdout.write.assert_called_with(cmd.version + "\n")