← Back to Pull requests

ROX-37572: Move the serial e2e tests into their feature suites, remove serial #1544

Closed
unknown closed this pull request without merging on Dec 03, 2026 23:04 UTC
View on GitHub
unknown unknown commented on Nov 24, 2026 06:59 UTC
Author

Summary

Dissolves the serial e2e suite (ROX-37572): each of its 22 tests
moves to the suite of the feature it tests, and tests/e2e/serial goes away. This was two PRs (#1544 and #1545);
it is now one. The first 12 commits move the tests, under 500 changed lines each, so they can be reviewed commit by
commit. The 10 commits after them are fixes from a second review. The commit messages say what changes and why.

| Tests | Suite | How they run |
|---|---|---|
| TestSuiteScan, TestPlatformAndNodeSuiteScan, TestKubeletConfigIsScannedAcrossReruns, TestResultServerNodeSelectorMaster, TestResultServerNodeSelectorWorker, TestTokenRulesPassOauthClientsConfigurable, TestScanHasProfileGUID, TestRemoveProfileScan | scan-config | parallel |
| TestHighProfileManualRulesHaveInstructions, TestInconsistentResult, TestOpenSCAPRuleMetadataPropagation | scan-config | alone, before the parallel tests |
| TestScanDeprecatedProfile | parsing | parallel (skipped in the critical-only run) |
| TestMustGatherImageWorksAsExpected | deployment | parallel |
| TestComplianceStateMetricSurvivesOperatorRestart, then TestPrometheusRuleComplianceAlert | deployment | alone |
| TestVariableTemplate | remediation | parallel |
| TestAutoRemediate, TestUpdateRemediation, TestKubeletConfigRemediation, TestRuntimeSSHConfigWithRemediation, TestUnapplyRemediation, TestResultServerTolerationsOnTaintedNode | remediation (lanes_test.go) | parallel, one per node lane |

Why some can't share the cluster:

  • TestInconsistentResult writes /etc/securetty on a worker, so concurrent node scans come back INCONSISTENT. It

  • removes the file however it ends.
  • Parallel tests that bind a shipped profile by name hold that profile's scan lock (HoldScanLocks), because the

  • suite controller adopts an existing scan of the same name: TestScanHasProfileGUID, TestRemoveProfileScan and
    TestScanSettingBinding, which was in scan-config already. A test that doesn't need the profile itself binds a
    TailoredProfile of it and needs no lock.
  • The two metrics tests set up the same RBAC as the parallel TestServiceMonitoringMetricsTarget, and one of them

  • restarts the operator.
  • TestOpenSCAPRuleMetadataPropagation can get the Rule metadata of another bundle until #1452 merges.

  • The lane tests reboot or taint nodes, so each gets its own MachineConfigPool lane.
  • Other changes:

  • HoldScanLocks gives a test scan locks in any suite. ScanPhaseTest, E2E_SCAN_PHASE_CONCURRENCY and the

  • WorkerScanRole helpers have no use left and go.
  • TestVariableTemplate restores the cluster's audit profile when it ends and waits for the kube-apiserver rollout,

  • about 11 minutes. It runs in parallel with the lane tests, so they don't wait behind it, and it waits for its
    remediation to be applied instead of for every node of the cluster.
  • TestPlatformAndNodeSuiteScan adds an htpasswd identity provider while it runs. It and

  • TestTokenRulesPassOauthClientsConfigurable hold the cluster-oauth lock, and TestScheduledSuitePlatformNoStorage
    takes either result of its identity provider rule.
  • TestRemoveProfileScan no longer requires its audit_profile_set result to be PASS. In serial it passed only

  • because TestVariableTemplate had left the audit profile at WriteRequestBodies.
  • make e2e-remediation takes over the lane settings: E2E_PARALLEL_POOLS, E2E_REMEDIATION_PARALLELISM (it was

  • E2E_SERIAL_PARALLELISM) and -restoreTestPools. It creates the lanes and leaves them in place unless
    E2E_RESTORE_TEST_POOLS=true. make e2e-serial stays as an alias until the openshift/release change for
    ROX-37663 drops the e2e-aws-serial job.

    Verification

    On an OCP 4.22 cluster (3 masters, 3 workers) with the master operator image, with the review fixes:

  • scan-config: 46 of 46 in 32 min, with 8 tests at a time as in CI.

  • remediation with 2 lanes: 11 of 11 twice, in 33 and 31 min. It was 43 min while TestVariableTemplate ran alone.

  • Both times kube-apiserver rolled out for 9 minutes while the lane tests ran, with no API error in the test log.
  • CI on the final head: every e2e job passed. With 5 lanes the remediation suite takes 18 min. It was 29 min

  • before the last 3 commits, 12 of them TestVariableTemplate waiting for the lane tests' nodes.

    Before the review fixes, on the same kind of cluster: deployment 11 of 11, parsing_tests 13 of 13.

    CI

  • Which tests run on every PR changes. e2e-aws-serial runs on every PR and, through the alias, now runs the

  • remediation suite, so the 7 tests there still run every time. The other 15 are in jobs that run only when
    matching paths change: scan-config (11), deployment (3) and parsing (1). ROX-37663 should widen those filters.
    For example, the deployment job doesn't run for pkg/controller/compliancesuite/, where the code that
    TestComplianceStateMetricSurvivesOperatorRestart guards lives, and no path-gated job runs for pkg/utils/ or
    pkg/xccdf/.
  • Lanes are capped at the worker count minus one: 5 on e2e-aws-serial (6 workers), 2 on e2e-aws-remediation

  • (3 workers) until ROX-37663 gives it 6. Until then both jobs run the remediation suite when its paths change.

    Update after merge

  • What merged matches the table above: TestScanHasProfileGUID and TestRemoveProfileScan call t.Parallel() and hold

  • their profiles' scan locks with HoldScanLocks, and TestVariableTemplate calls t.Parallel() in the remediation
    suite. An earlier version of this description had them running alone.
  • openshift/release#89893 (ROX-37663) removed the e2e-aws-serial jobs on Dec 3, and #1555 drops the

  • make e2e-serial alias along with the other review follow-ups.

    Generated with Claude Code

    Diff: 650 lines (+487 / -163) across 8 files Reviewer: rhmdnd Review duration: 13924m
    All Vouch review confidence checks passed
    Residual risk 0.21 = Change Risk (0.52) × (1 − Review Confidence (0.60)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.52 · 650 lines diff across 8 files
    0.52
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    60%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.388
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #1544"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 60.5% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 52% (MEDIUM) · Higher = larger blast radius
    52%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 60.5% · Lower = rushed or shallow review
    60.5%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 20.5% · Safe to merge
    20.5%