Skip to content

[BUG]: simple/ and reap_old_logs/ operator-agent assertions do not gate (no set -e) #680

Closed

Description

@rice-riley

Skyhook Version

main at 1787cc92.

Installation method

Source (built from repo)

Kubernetes Version

Any; this is test-harness behaviour.

Component

Tests (e2e / chainsaw)

Describe the bug

Three assertion blocks in the pre-existing operator-agent scenarios do not gate. Chainsaw runs script.content as sh -c with no set -e, so only the last command's exit status reaches the test and every check_node.sh call above it is decorative:

  • k8s-tests/operator-agent/simple/chainsaw-test.yaml, the post-assert block: five assertions (log content ×2, START flag, step flag path, history file) and only the last one, ls .../history, gates. The log-content and flag-path checks — the ones that would notice a format drift between agents — cannot fail the test.
  • k8s-tests/operator-agent/reap_old_logs/chainsaw-test.yaml, the seed block ('^7$' count) and the survivor block ('^5$' count plus the newest content check): two blocks, three assertions, of which one gates.

interrupt/, dont_write_logs/, and the scenarios added in #605 and #673 already set set -e; this is the remainder. Brian identified the class of defect reviewing #605 (see its check_results thread); these are the pre-existing instances I flagged there and did not touch because they are contract scenarios.

Steps to reproduce

# Break an early assertion in simple/ and observe the suite still passes:
#   sed -i 's/Hello, world!/Goodbye, world!/' k8s-tests/operator-agent/simple/chainsaw-test.yaml
#   make -C operator operator-agent-tests   # green

Relevant log output

# n/a — the failure mode is a false pass, so there is no log to show.

Environment details

n/a

Additional context

This matters for #222, whose cutover argument rests on "the operator-agent suite passes." For simple/ that sentence currently means one of five assertions passed. The fix is set -e as the first line of each of the three blocks; the cleanup blocks (rm -rf ... || true) are intentionally non-gating and stay as they are.

Code of Conduct

  • I agree to follow Skyhook's Code of Conduct
  • I have searched the open bugs and have found no duplicates for this bug report

Activity

  1. added theissue type on Sep 23, 2026
  2. added
    needs-triageAwaiting initial triage by a maintainer
    component/testsEnd-to-end / chainsaw test suites (k8s-tests)
    and removed
    needs-triageAwaiting initial triage by a maintainer
    on Sep 23, 2026
  3. added 3 commits that reference this issue on Sep 23, 2026
    13fdb29
    6d23a1d
    e19fff2
  4. added a commit that references this issue on Sep 30, 2026
    1497764
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

component/testsEnd-to-end / chainsaw test suites (k8s-tests)

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions