Skip to content

fix(tests): replay the synthetic filebeat cases from dfe-transform-vrl - #165

Merged
catinspace-au merged 1 commit into
mainfrom
fix/filebeat-synthetic-cases
Nov 15, 2026
Merged

catinspace-au merged 1 commit into
mainfrom
fix/filebeat-synthetic-cases

Conversation

@catinspace-au

Copy link
Copy Markdown
Contributor

dfe-transform-vrl replaced its filebeat test archive with 31 written cases. e2e::filebeat_kafka now reads those cases from a checkout beside this repo.

tests/common/filebeat.rs mirrors dfe-transform-vrl's loader and comparison. It keeps the DFE_TRANSFORM_VRL_DIR lookup and the lookup beside this repo. The test pairs each output to its case by a root _case field.

The test keeps four assertions:

  • Every event comes out.
  • The unmatched probe is tagged.
  • Every case matches.
  • All three module branches ran.

Remove tar, flate2 and chrono from dev-dependencies. Remove tar, filetime and xattr from Cargo.lock.

No test was removed. The 31 cases cover fewer lines than the old archive. None is a Meraki ip_flow_end line.

The e2e filebeat test passes in 75 seconds on a 32-core build host against dfe-transform-vrl at eb87c9b.

  • cargo check --locked --tests passes.
  • cargo clippy --all-targets -- -D warnings passes.

dfe-transform-vrl no longer ships the filebeat test archive, so e2e::filebeat_kafka failed on every run. The test now reads tests/fixtures/filebeat/cases.yaml from the same sibling checkout (or DFE_TRANSFORM_VRL_DIR). It checks each output against the fields named by its case. It pairs outputs to cases by a root _case field.

tests/common/filebeat.rs mirrors the loader and comparison in dfe-transform-vrl. Remove the tar, flate2 and chrono dev-dependencies, used only to read and check the archive. Remove tar's filetime and xattr from Cargo.lock.

The round-trip test keeps its four assertions:
- every event comes out
- the unmatched probe is tagged
- every case matches
- all three module branches ran
@catinspace-au
catinspace-au merged commit 6578941 into main Nov 15, 2026
23 checks passed
@catinspace-au
catinspace-au deleted the fix/filebeat-synthetic-cases branch November 15, 2026 18:18
catinspace-au added a commit that referenced this pull request Nov 15, 2026
Brings in #165, whose filebeat tests replay dfe-transform-vrl's synthetic cases. tests/TESTING.md keeps main's filebeat paragraph and this branch's edits to the rest of the page.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant