Skip to content

Fix E2E tests hanging indefinitely during PR validation#4906

Closed
Copilot wants to merge 2 commits into
mainfrom
copilot/fix-e2e-tests-not-running
Closed

Fix E2E tests hanging indefinitely during PR validation#4906
Copilot wants to merge 2 commits into
mainfrom
copilot/fix-e2e-tests-not-running

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 20, 2026

The summary job in deploy_tre_reusable.yml had several issues that caused the "Deploy PR / Run E2E Tests (Smoke)" check to remain permanently stuck in in_progress state, making E2E tests appear to hang indefinitely from the PR perspective.

What is being addressed

When triggering E2E tests via /test comment, the "Deploy PR / Run E2E Tests (Smoke)" check would remain in_progress forever and tests would never be reported as completed. Additionally, test_shared_service_templates.py was missing the asyncio loop scope marker present in all other test files.

How is this addressed

summary job fixes (deploy_tre_reusable.yml):

  • Added actions: read permission — required by im-open/workflow-conclusion to call listJobsForWorkflowRun API. Without it, the action fails silently, the WORKFLOW_CONCLUSION env var is never set, and the check status update is skipped
  • Removed environment: ${{ inputs.environmentName }} — the summary job accesses no environment variables or secrets; having it set means each workflow run requires a separate per-job environment approval, blocking the job unnecessarily
  • Changed Report check status step condition from if: inputs.prHeadSha != '' to if: always() && inputs.prHeadSha != '' — ensures the check is updated to completed even if workflow-conclusion fails

Calling workflows (pr_comment_bot.yml, deploy_tre.yml, deploy_tre_branch.yml):

  • Added actions: read to the job-level permissions block so the permission propagates into the reusable workflow

test_shared_service_templates.py:

  • Added pytestmark = pytest.mark.asyncio(loop_scope="session") to match every other test file and eliminate event loop scope inconsistency with pytest-asyncio 0.24.0

CHANGELOG.md: Updated with bug fix entry.

Copilot AI linked an issue May 20, 2026 that may be closed by this pull request
…om summary, fix asyncio mark

Agent-Logs-Url: https://github.com/microsoft/AzureTRE/sessions/bc627f57-dcc6-4fc5-b80c-17f541d3859e

Co-authored-by: rudolphjacksonm <13438569+rudolphjacksonm@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix E2E tests hanging during PR validation Fix E2E tests hanging indefinitely during PR validation May 20, 2026
Copilot AI requested a review from rudolphjacksonm May 20, 2026 20:13
@rudolphjacksonm
Copy link
Copy Markdown
Collaborator

/test

@github-actions
Copy link
Copy Markdown

🤖 pr-bot 🤖

⚠️ When using /test on external PRs, the SHA of the checked commit must be specified

(in response to this comment from @rudolphjacksonm)

@rudolphjacksonm
Copy link
Copy Markdown
Collaborator

/test 8c907df

@github-actions
Copy link
Copy Markdown

🤖 pr-bot 🤖

🏃 Running tests: https://github.com/microsoft/AzureTRE/actions/runs/26193010183 (with refid bfdac97b)

(in response to this comment from @rudolphjacksonm)

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.

E2E Tests no longer running

2 participants