Skip to content

TRT-2573: Show non-blocking failure message in JUnit failure output#30921

Open
stbenjam wants to merge 1 commit intoopenshift:mainfrom
stbenjam:output
Open

TRT-2573: Show non-blocking failure message in JUnit failure output#30921
stbenjam wants to merge 1 commit intoopenshift:mainfrom
stbenjam:output

Conversation

@stbenjam
Copy link
Member

@stbenjam stbenjam commented Mar 23, 2026

Summary

  • Move the "NON-BLOCKING FAILURE" message into the JUnit FailureOutput.Output field so it's visible in the Spyglass JUnit lens in Prow
  • Previously, the message was prepended to testOutputBytes which gets truncated to the last ~100 lines in the failure output, making it invisible for tests with longer output
  • The existing informing test in test/extended/extension/extension.go can be used to verify this works in CI

Fixes TRT-2573

Example https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/30921/pull-ci-openshift-origin-main-e2e-aws-ovn-fips/2036093813532921856

Test plan

  • Verify the [Suite:openshift/ote] suite runs in CI and the failing informing test shows "NON-BLOCKING FAILURE" in the JUnit lens

🤖 Generated with Claude Code

Move the "NON-BLOCKING FAILURE" message from testOutputBytes (which
is prepended to the beginning and not visible in the JUnit failure
lens since it shows the last ~100 lines) into the JUnit
FailureOutput.Output field directly. This ensures informing test
failures are clearly marked as non-blocking when viewed in the
Spyglass JUnit lens in Prow.

Fixes TRT-2573

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@openshift-ci-robot
Copy link

Pipeline controller notification
This repo is configured to use the pipeline controller. Second-stage tests will be triggered either automatically or after lgtm label is added, depending on the repository configuration. The pipeline controller will automatically detect which contexts are required and will utilize /test Prow commands to trigger the second stage.

For optional jobs, comment /test ? to see a list of all defined jobs. To trigger manually all jobs from second stage use /pipeline required command.

This repository is configured in: automatic mode

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Mar 23, 2026
@coderabbitai
Copy link

coderabbitai bot commented Mar 23, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 9b1c7a72-64f9-4546-b03d-159c8aa0f815

📥 Commits

Reviewing files that changed from the base of the PR and between 785f8b0 and cd8b853.

📒 Files selected for processing (2)
  • pkg/test/ginkgo/cmd_runsuite.go
  • pkg/test/ginkgo/junit.go
💤 Files with no reviewable changes (1)
  • pkg/test/ginkgo/cmd_runsuite.go

Walkthrough

Non-blocking failure handling logic was refactored across two files: removal of output rewriting in cmd_runsuite.go and addition of conditional failure message wrapping in junit.go based on extensionTestResult lifecycle status. The control flow for classifying and printing failures remains unchanged.

Changes

Cohort / File(s) Summary
Non-blocking failure handling
pkg/test/ginkgo/cmd_runsuite.go
Removed logic that prepended *** NON-BLOCKING FAILURE... explanatory message to test output bytes. Control flow for classifying and reporting failures is preserved.
Failure message rendering
pkg/test/ginkgo/junit.go
Added extensiontests import and introduced conditional failure message wrapping. For failed tests with non-nil extensionTestResult having Lifecycle equal to extensiontests.LifecycleInforming, failure messages are now wrapped with *** NON-BLOCKING FAILURE... prefix in JUnit output.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~22 minutes

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 golangci-lint (2.11.3)

Error: can't load config: unsupported version of the configuration: "" See https://golangci-lint.run/docs/product/migration-guide for migration instructions
The command is terminated due to an error: can't load config: unsupported version of the configuration: "" See https://golangci-lint.run/docs/product/migration-guide for migration instructions


Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Mar 23, 2026

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@stbenjam
Copy link
Member Author

/test e2e-aws-ovn-fips

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Mar 23, 2026

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: stbenjam

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Mar 23, 2026
@stbenjam stbenjam changed the title Show non-blocking failure message in JUnit failure output TRT-2573: Show non-blocking failure message in JUnit failure output Mar 23, 2026
@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Mar 23, 2026
@openshift-ci-robot
Copy link

openshift-ci-robot commented Mar 23, 2026

@stbenjam: This pull request references TRT-2573 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set.

Details

In response to this:

Summary

  • Move the "NON-BLOCKING FAILURE" message into the JUnit FailureOutput.Output field so it's visible in the Spyglass JUnit lens in Prow
  • Previously, the message was prepended to testOutputBytes which gets truncated to the last ~100 lines in the failure output, making it invisible for tests with longer output
  • The existing informing test in test/extended/extension/extension.go can be used to verify this works in CI

Fixes TRT-2573

Test plan

  • Verify the [Suite:openshift/ote] suite runs in CI and the failing informing test shows "NON-BLOCKING FAILURE" in the JUnit lens

🤖 Generated with Claude Code

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-ci-robot
Copy link

openshift-ci-robot commented Mar 23, 2026

@stbenjam: This pull request references TRT-2573 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set.

Details

In response to this:

Summary

  • Move the "NON-BLOCKING FAILURE" message into the JUnit FailureOutput.Output field so it's visible in the Spyglass JUnit lens in Prow
  • Previously, the message was prepended to testOutputBytes which gets truncated to the last ~100 lines in the failure output, making it invisible for tests with longer output
  • The existing informing test in test/extended/extension/extension.go can be used to verify this works in CI

Fixes TRT-2573

Example https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/30921/pull-ci-openshift-origin-main-e2e-aws-ovn-fips/2036093813532921856

Test plan

  • Verify the [Suite:openshift/ote] suite runs in CI and the failing informing test shows "NON-BLOCKING FAILURE" in the JUnit lens

🤖 Generated with Claude Code

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@stbenjam stbenjam marked this pull request as ready for review March 23, 2026 18:41
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Mar 23, 2026
@openshift-ci openshift-ci bot requested review from deads2k and sjenning March 23, 2026 18:41
@openshift-ci-robot
Copy link

Scheduling required tests:
/test e2e-aws-csi
/test e2e-aws-ovn-fips
/test e2e-aws-ovn-microshift
/test e2e-aws-ovn-microshift-serial
/test e2e-aws-ovn-serial-1of2
/test e2e-aws-ovn-serial-2of2
/test e2e-gcp-csi
/test e2e-gcp-ovn
/test e2e-gcp-ovn-upgrade
/test e2e-metal-ipi-ovn-ipv6
/test e2e-vsphere-ovn
/test e2e-vsphere-ovn-upi

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Mar 24, 2026

@stbenjam: all tests passed!

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants