def test_details_multiple_with_normal_line_label_false(self): expected = [{'foo': 'BUILD', 'bar': 'ERROR', 'bee': 'None'}, {'aaa': 'VVVVV', 'bbb': 'WWWWW', 'ccc': 'XXXXX'}] actual = output_parser.details_multiple(self.DETAILS_LINES1 + self.DETAILS_LINES2) self.assertIsInstance(actual, list) self.assertEqual(expected, actual)
def test_details_multiple_with_normal_line_label_true(self): expected = [ {"__label": "First Table", "foo": "BUILD", "bar": "ERROR", "bee": "None"}, {"__label": "Second Table", "aaa": "VVVVV", "bbb": "WWWWW", "ccc": "XXXXX"}, ] actual = output_parser.details_multiple(self.DETAILS_LINES1 + self.DETAILS_LINES2, with_label=True) self.assertIsInstance(actual, list) self.assertEqual(expected, actual)
def test_details_multiple_with_normal_line_label_false(self): expected = [{ 'foo': 'BUILD', 'bar': 'ERROR', 'bee': 'None' }, { 'aaa': 'VVVVV', 'bbb': 'WWWWW', 'ccc': 'XXXXX' }] actual = output_parser.details_multiple(self.DETAILS_LINES1 + self.DETAILS_LINES2) self.assertIsInstance(actual, list) self.assertEqual(expected, actual)
def test_details_multiple_with_normal_line_label_false(self): expected = [{"foo": "BUILD", "bar": "ERROR", "bee": "None"}, {"aaa": "VVVVV", "bbb": "WWWWW", "ccc": "XXXXX"}] actual = output_parser.details_multiple(self.DETAILS_LINES1 + self.DETAILS_LINES2) self.assertIsInstance(actual, list) self.assertEqual(expected, actual)