Skip to content

Commit d41e598

Browse files
committed
Update ppl-bugfix-reference: prefer datarows match over length check
YAML REST tests should assert actual row content, not just count. Learned from #5174 where total-only assertion missed incorrect values. Signed-off-by: Heng Qian <qianheng@amazon.com>
1 parent 1f7053d commit d41e598

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

.claude/harness/ppl-bugfix-reference.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,9 +109,13 @@ teardown:
109109
headers: { Content-Type: 'application/json' }
110110
ppl: { body: { query: "source=test_issue_<ISSUE> | <your PPL>" } }
111111
- match: { total: <expected> }
112-
- length: { datarows: <expected> }
112+
- match: { datarows: [ [ <row1_val1>, <row1_val2> ], [ <row2_val1>, <row2_val2> ] ] }
113113
```
114114
115+
> **Always include `datarows` assertions** — verifying only `total` and `schema` will miss
116+
> wrong values. Count the expected output groups carefully (e.g., for `chart ... by <col>`,
117+
> count distinct (row_split, col_split) groups after null filtering, not the number of input rows).
118+
115119
---
116120

117121
## Symptom → Fix Path

0 commit comments

Comments
 (0)