Skip to content

feat: add test_step_outcome input to detect silent test failures#175

Closed
jd wants to merge 1 commit intomainfrom
devs/jd/exit-code/Ie46d801917402e93726e1d182c8df3ba2c819b01
Closed

feat: add test_step_outcome input to detect silent test failures#175
jd wants to merge 1 commit intomainfrom
devs/jd/exit-code/Ie46d801917402e93726e1d182c8df3ba2c819b01

Conversation

@jd
Copy link
Copy Markdown
Member

@jd jd commented Apr 2, 2026

Pass the test runner step outcome to set MERGIFY_TEST_EXIT_CODE,
allowing the CLI to detect cases where the runner crashed but the
JUnit report appears clean.

Co-Authored-By: Claude Opus 4.6 (1M context) noreply@anthropic.com

Pass the test runner step outcome to set MERGIFY_TEST_EXIT_CODE,
allowing the CLI to detect cases where the runner crashed but the
JUnit report appears clean.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Change-Id: Ie46d801917402e93726e1d182c8df3ba2c819b01
Copilot AI review requested due to automatic review settings April 2, 2026 15:32
@mergify mergify bot had a problem deploying to Mergify Merge Protections April 2, 2026 15:32 Failure
@mergify
Copy link
Copy Markdown
Contributor

mergify bot commented Apr 2, 2026

Merge Protections

Your pull request matches the following merge protections and will not be merged until they are valid.

🔴 🤖 Continuous Integration

This rule is failing.
  • all of:
    • check-success=all-greens

🔴 👀 Review Requirements

This rule is failing.
  • any of:
    • #approved-reviews-by>=1
    • author = dependabot[bot]
    • author = mergify-ci-bot
    • author = renovate[bot]

🔴 🔎 Reviews

This rule is failing.
  • #review-threads-unresolved = 0
  • #changes-requested-reviews-by = 0
  • #review-requested = 0

🟢 Enforce conventional commit

Wonderful, this rule succeeded.

Make sure that we follow https://www.conventionalcommits.org/en/v1.0.0/

  • title ~= ^(fix|feat|docs|style|refactor|perf|test|build|ci|chore|revert)(?:\(.+\))?:

🟢 📕 PR description

Wonderful, this rule succeeded.
  • body ~= (?ms:.{48,})

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new optional test_step_outcome input to the composite GitHub Action so it can set MERGIFY_TEST_EXIT_CODE for mergify ci junit-process, enabling detection of “silent” test-runner crashes even when JUnit output looks clean.

Changes:

  • Introduce test_step_outcome input in action.yml for passing steps.<id>.outcome.
  • Derive and export MERGIFY_TEST_EXIT_CODE from test_step_outcome when running the junit-process action.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +33 to +39
test_step_outcome:
description: |
Outcome of the test runner step (e.g. steps.<id>.outcome).
Pass this to detect silent failures where the test runner crashed
but the JUnit report appears clean.
Values: 'success', 'failure', 'cancelled', or omit entirely.
required: false
Copy link

Copilot AI Apr 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

README.md action docs are auto-generated from action.yml and CI’s autodoc job fails if README.md isn’t regenerated. Since this PR adds a new input, README.md needs to be updated by running ./generate-doc.sh (or tj-actions/auto-doc) and committing the result.

Copilot uses AI. Check for mistakes.
Outcome of the test runner step (e.g. steps.<id>.outcome).
Pass this to detect silent failures where the test runner crashed
but the JUnit report appears clean.
Values: 'success', 'failure', 'cancelled', or omit entirely.
Copy link

Copilot AI Apr 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

steps.<id>.outcome can also be skipped in GitHub Actions. This input’s description currently lists only success, failure, and cancelled, but the implementation will treat any other non-empty value (including skipped) as a failing exit code. Please either document skipped explicitly (and how it should map), or add an input validation check to reject unexpected values to avoid confusing/incorrect behavior when users pass steps.<id>.outcome.

Suggested change
Values: 'success', 'failure', 'cancelled', or omit entirely.
Values: 'success', 'failure', 'cancelled', 'skipped', or omit entirely.
Note: any non-empty value other than 'success' is treated as a failing outcome.

Copilot uses AI. Check for mistakes.
@jd jd marked this pull request as ready for review April 2, 2026 15:37
@jd
Copy link
Copy Markdown
Member Author

jd commented Apr 2, 2026

Duplicate of #174

@jd jd marked this as a duplicate of #174 Apr 2, 2026
@jd jd closed this Apr 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

2 participants