@@ -2,23 +2,52 @@ name: start-integration-tests
22
33on :
44 workflow_dispatch :
5+ merge_group :
56
67jobs :
7- # Trigger for pull requests.
8- #
8+ # Auto-approve integration tests for merge queue.
9+ # The tests already passed on the PR, so we don't need to run them again.
10+ auto-approve :
11+ if : github.event_name == 'merge_group'
12+
13+ runs-on :
14+ group : databricks-deco-testing-runner-group
15+ labels : ubuntu-latest-deco
16+
17+ permissions :
18+ checks : write
19+ contents : read
20+
21+ steps :
22+ - name : Auto-approve Check for Merge Queue
23+ uses : actions/github-script@v7
24+ with :
25+ script : |
26+ await github.rest.checks.create({
27+ owner: context.repo.owner,
28+ repo: context.repo.repo,
29+ name: 'Integration Tests',
30+ head_sha: context.sha,
31+ status: 'completed',
32+ conclusion: 'success',
33+ output: {
34+ title: 'Integration Tests',
35+ summary: 'Auto-approved for merge queue (tests already passed on PR)'
36+ }
37+ });
38+
39+ # Trigger integration tests for PRs.
940 # This workflow triggers the integration test workflow in a different repository.
1041 # It requires secrets from the "test-trigger-is" environment, which are only available to authorized users.
1142 trigger :
43+ if : github.event_name == 'workflow_dispatch'
44+
1245 runs-on :
1346 group : databricks-deco-testing-runner-group
1447 labels : ubuntu-latest-deco
1548
1649 environment : " test-trigger-is"
1750
18- # Only run this job for PRs from branches on the main repository and not from forks.
19- # Workflows triggered by PRs from forks don't have access to the "test-trigger-is" environment.
20- if : " ${{ !github.event.pull_request.head.repo.fork }}"
21-
2251 steps :
2352 - name : Generate GitHub App Token for Workflow Trigger
2453 id : generate-token
0 commit comments