with self.assertRaises(SystemExit) as cm:
    tx_names = map_reader.get_tx_names(INCOMPLETE_MAPPING_FILE)
self.assertEqual(cm.exception.code, 1)
Is it possible for a unit test to assert that a method calls sys.exit()