Index: tko/parsers/version_0_unittest.py |
diff --git a/tko/parsers/version_0_unittest.py b/tko/parsers/version_0_unittest.py |
index abf7b676309566d837a5577e57e8ec11292ff5ae..286e5bb2f735e5e904095def00678c540cd55125 100755 |
--- a/tko/parsers/version_0_unittest.py |
+++ b/tko/parsers/version_0_unittest.py |
@@ -273,11 +273,19 @@ class test_status_line(unittest.TestCase): |
self.assertEquals(line.optional_fields, {}) |
- def test_parse_line_fails_on_bad_optional_fields(self): |
- input_data = "GOOD\tfield1\tfield2\tfield3\tfield4" |
- self.assertRaises(AssertionError, |
- version_0.status_line.parse_line, |
- input_data) |
+ def test_parse_line_handles_tabs_in_reason(self): |
+ input_data = ("\tEND FAIL\t----\ttest\tfield1=val1\tfield2=val2\tReason" |
+ " with\ta\tcouple\ttabs") |
+ |
+ line = version_0.status_line.parse_line(input_data) |
+ self.assertEquals(line.indent, 1) |
+ self.assertEquals(line.type, "END") |
+ self.assertEquals(line.status, "FAIL") |
+ self.assertEquals(line.subdir, None) |
+ self.assertEquals(line.testname, "test") |
+ self.assertEquals(line.reason, "Reason with\ta\tcouple\ttabs") |
+ self.assertEquals(line.optional_fields, {"field1": "val1", |
+ "field2": "val2"}) |
if __name__ == "__main__": |