Commit 412a159
committed
[oss] TestRunner: nicer failure diagnostics
Before:
```
FAIL
Exception: HUnitFailure (Just (SrcLoc {srcLocPackage = "glean-0.1.0.0-inplace-regression-test-lib", srcLocModule = "Glean.Regression.Snapshot.Result", srcLocFile = "glean/test/regression/Glean/Regression/Snapshot/Result.hs", srcLocStartLine = 34, srcLocStartCol = 25, srcLocEndLine = 34, srcLocEndCol = 44})) (Reason "filerange.out: unexpected result\n19,29d18\n< \"columnBegin\": 1,\n< \"lineEnd\": 53,\n< \"columnEnd\": 1\n< }\n< }\n< },\n< {\n< \"key\": {\n< \"file\": { \"key\": \"example.ts\" },\n< \"range\": {\n< \"lineBegin\": 9,\n74,84d62\n< \"columnBegin\": 1,\n< \"lineEnd\": 42,\n< \"columnEnd\": 3\n< }\n< }\n< },\n< {\n< \"key\": {\n< \"file\": { \"key\": \"example.ts\" },\n< \"range\": {\n< \"lineBegin\": 14,\n107,117d84\n< \"columnBegin\": 3,\n< \"lineEnd\": 33,\n< \"columnEnd\": 3\n< }\n< }\n< },\n< {\n< \"key\": {\n< \"file\": { \"key\": \"example.ts\" },\n< \"range\": {\n< \"lineBegin\": 15,\n382,392d348\n< \"columnBegin\": 3,\n< \"lineEnd\": 41,\n< \"columnEnd\": 5\n< }\n< }\n< },\n< {\n< \"key\": {\n< \"file\": { \"key\": \"example.ts\" },\n< \"range\": {\n< \"lineBegin\": 34,\n528,538d483\n< }\n< }\n< },\n< {\n< \"key\": {\n< \"file\": { \"key\": \"example.ts\" },\n< \"range\": {\n< \"lineBegin\": 46,\n< \"columnBegin\": 1,\n< \"lineEnd\": 52,\n< \"columnEnd\": 1\n\nfilerange.perf: unexpected result\n3c3\n< \"facts_searched\": { \"scip.FileRange.1\": 62 },\n---\n> \"facts_searched\": { \"scip.FileRange.1\": 57 },\n\n")
```
After:
```
FAIL (4.24s)
glean/test/regression/Glean/Regression/Snapshot/Result.hs:34:
filerange.out: unexpected result
19,29d18
< "columnBegin": 1,
< "lineEnd": 53,
< "columnEnd": 1
< }
< }
< },
< {
< "key": {
< "file": { "key": "example.ts" },
< "range": {
< "lineBegin": 9,
74,84d62
< "columnBegin": 1,
< "lineEnd": 42,
< "columnEnd": 3
< }
< }
< },
< {
< "key": {
< "file": { "key": "example.ts" },
< "range": {
< "lineBegin": 14,
107,117d84
< "columnBegin": 3,
< "lineEnd": 33,
< "columnEnd": 3
< }
< }
< },
< {
< "key": {
< "file": { "key": "example.ts" },
< "range": {
< "lineBegin": 15,
382,392d348
< "columnBegin": 3,
< "lineEnd": 41,
< "columnEnd": 5
< }
< }
< },
< {
< "key": {
< "file": { "key": "example.ts" },
< "range": {
< "lineBegin": 34,
528,538d483
< }
< }
< },
< {
< "key": {
< "file": { "key": "example.ts" },
< "range": {
< "lineBegin": 46,
< "columnBegin": 1,
< "lineEnd": 52,
< "columnEnd": 1
filerange.perf: unexpected result
3c3
< "facts_searched": { "scip.FileRange.1": 62 },
---
> "facts_searched": { "scip.FileRange.1": 57 },
```1 parent d44726a commit 412a159
2 files changed
Lines changed: 31 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
228 | 228 | | |
229 | 229 | | |
230 | 230 | | |
231 | | - | |
| 231 | + | |
232 | 232 | | |
233 | 233 | | |
234 | 234 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
| 11 | + | |
11 | 12 | | |
12 | 13 | | |
13 | 14 | | |
14 | | - | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
15 | 18 | | |
16 | 19 | | |
17 | 20 | | |
18 | 21 | | |
19 | 22 | | |
20 | 23 | | |
21 | 24 | | |
22 | | - | |
| 25 | + | |
23 | 26 | | |
24 | 27 | | |
25 | 28 | | |
| |||
40 | 43 | | |
41 | 44 | | |
42 | 45 | | |
43 | | - | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
0 commit comments