Commit 38fa352
committed
test(integration): demo-data drift — rename hardcoded 'host' → 'dest_host'
Root cause: commit 301dcd5 (chore(lookups): trim demo CSVs from 19 to 3
+ refactor refs) reduced lookups/rule_csv_map.csv from 9 mappings to
1 (DR55_brute_force_login → DR55_brute_force_users.csv). The
surviving CSV's columns are:
user, src_ip, dest_host, threshold, auth_method, Comment,
Expires, _added_by, _added_at
— no plain "host" column. Integration tests that call mapping[0]
and then submit a column_removal/approval request for column "host"
fail at approval-replay time with:
{"error": "Column 'host' no longer exists",
"request_id": "..."}
The error message is honest — "host" never existed in that CSV.
DR130_priv_escalation.csv (which DOES have a "host" column) is no
longer in the demo mapping after the trim.
Sites changed (all read from mapping[0] and hardcoded "host"):
tests/integration/test_approval_workflow.py:97 (default kwarg)
tests/integration/test_approval_workflow.py:463-464
tests/integration/test_audit_emission.py:197-198
tests/integration/test_audit_emission.py:267-268
tests/integration/test_notification_payload.py:115-116
tests/integration/test_post_happy_paths.py:467-472 (helper
_submit_column_removal)
tests/integration/test_post_happy_paths.py:517-522
(test_approve_response_shape_for_column_removal — the only
FAILED test on each run; the SKIPPED tests in
test_limit_edge_cases.py and test_notification_payload.py
call helpers that depend on this path)
Sites left as "host" (test creates its own CSV via headers=["host"]
— self-contained, no dependency on demo state):
tests/integration/test_post_error_paths.py:83 / 99 / 122 (CSV
creation tests — these CREATE a CSV with header "host")
tests/integration/test_post_happy_paths.py:685 / 690 (bulk-row
submit test; the submit endpoint does not validate row-column
existence so this passes regardless)
Independent evidence: 5 consecutive failed Integration Tests runs
(26307468975 / 26293782287 / 26293068253 / 26292468446 /
26292308961) all surfaced the SAME single FAILED line in the same
test, deterministic across commits b14b3c9 / 91d9d22 / ab53066 /
a48f6c2 / 4330149.
Verification path: next Integration Tests run on main should show
1 fewer failure (target = 0 failed, 357 passed instead of the
prior 1 failed, 356 passed). The 3 skips traced to the same root
cause should also resolve (the test_limit_edge_cases.py skip on
"Rate limit exceeded" is a separate issue — see follow-up).1 parent 250119f commit 38fa352
4 files changed
Lines changed: 15 additions & 15 deletions
File tree
- tests/integration
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
94 | 94 | | |
95 | 95 | | |
96 | 96 | | |
97 | | - | |
| 97 | + | |
98 | 98 | | |
99 | 99 | | |
100 | 100 | | |
| |||
460 | 460 | | |
461 | 461 | | |
462 | 462 | | |
463 | | - | |
464 | | - | |
| 463 | + | |
| 464 | + | |
465 | 465 | | |
466 | 466 | | |
467 | 467 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
194 | 194 | | |
195 | 195 | | |
196 | 196 | | |
197 | | - | |
198 | | - | |
| 197 | + | |
| 198 | + | |
199 | 199 | | |
200 | 200 | | |
201 | 201 | | |
| |||
264 | 264 | | |
265 | 265 | | |
266 | 266 | | |
267 | | - | |
268 | | - | |
| 267 | + | |
| 268 | + | |
269 | 269 | | |
270 | 270 | | |
271 | 271 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
112 | 112 | | |
113 | 113 | | |
114 | 114 | | |
115 | | - | |
116 | | - | |
| 115 | + | |
| 116 | + | |
117 | 117 | | |
118 | 118 | | |
119 | 119 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
465 | 465 | | |
466 | 466 | | |
467 | 467 | | |
468 | | - | |
| 468 | + | |
469 | 469 | | |
470 | | - | |
| 470 | + | |
471 | 471 | | |
472 | | - | |
| 472 | + | |
473 | 473 | | |
474 | 474 | | |
475 | 475 | | |
| |||
515 | 515 | | |
516 | 516 | | |
517 | 517 | | |
518 | | - | |
| 518 | + | |
519 | 519 | | |
520 | | - | |
| 520 | + | |
521 | 521 | | |
522 | | - | |
| 522 | + | |
523 | 523 | | |
524 | 524 | | |
525 | 525 | | |
| |||
0 commit comments