Enable merge queues (#10515)
* Enable merge queues * Iterate * Iterate * iterate * Fix check blocked and others not running in MQ * Add concurrency * Iterate * Iterate * Iterate * Iterate * Update pr-details action
This commit is contained in:
parent
7321277ed8
commit
b73032145d
4 changed files with 28 additions and 2 deletions
2
.github/workflows/element-web.yaml
vendored
2
.github/workflows/element-web.yaml
vendored
|
@ -6,6 +6,8 @@ on:
|
||||||
schedule:
|
schedule:
|
||||||
- cron: "17 4 * * 1-5" # every weekday at 04:17 UTC
|
- cron: "17 4 * * 1-5" # every weekday at 04:17 UTC
|
||||||
pull_request: {}
|
pull_request: {}
|
||||||
|
merge_group:
|
||||||
|
types: [checks_requested]
|
||||||
push:
|
push:
|
||||||
branches: [develop, master]
|
branches: [develop, master]
|
||||||
repository_dispatch:
|
repository_dispatch:
|
||||||
|
|
2
.github/workflows/pull_request.yaml
vendored
2
.github/workflows/pull_request.yaml
vendored
|
@ -2,6 +2,8 @@ name: Pull Request
|
||||||
on:
|
on:
|
||||||
pull_request_target:
|
pull_request_target:
|
||||||
types: [opened, edited, labeled, unlabeled, synchronize]
|
types: [opened, edited, labeled, unlabeled, synchronize]
|
||||||
|
merge_group:
|
||||||
|
types: [checks_requested]
|
||||||
jobs:
|
jobs:
|
||||||
action:
|
action:
|
||||||
uses: matrix-org/matrix-js-sdk/.github/workflows/pull_request.yaml@develop
|
uses: matrix-org/matrix-js-sdk/.github/workflows/pull_request.yaml@develop
|
||||||
|
|
2
.github/workflows/static_analysis.yaml
vendored
2
.github/workflows/static_analysis.yaml
vendored
|
@ -1,6 +1,8 @@
|
||||||
name: Static Analysis
|
name: Static Analysis
|
||||||
on:
|
on:
|
||||||
pull_request: {}
|
pull_request: {}
|
||||||
|
merge_group:
|
||||||
|
types: [checks_requested]
|
||||||
push:
|
push:
|
||||||
branches: [develop, master]
|
branches: [develop, master]
|
||||||
repository_dispatch:
|
repository_dispatch:
|
||||||
|
|
24
.github/workflows/tests.yml
vendored
24
.github/workflows/tests.yml
vendored
|
@ -1,6 +1,8 @@
|
||||||
name: Tests
|
name: Tests
|
||||||
on:
|
on:
|
||||||
pull_request: {}
|
pull_request: {}
|
||||||
|
merge_group:
|
||||||
|
types: [checks_requested]
|
||||||
push:
|
push:
|
||||||
branches: [develop, master]
|
branches: [develop, master]
|
||||||
repository_dispatch:
|
repository_dispatch:
|
||||||
|
@ -19,6 +21,7 @@ concurrency:
|
||||||
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }}
|
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }}
|
||||||
cancel-in-progress: true
|
cancel-in-progress: true
|
||||||
env:
|
env:
|
||||||
|
ENABLE_COVERAGE: ${{ github.event_name != 'merge_group' && inputs.disable_coverage != 'true' }}
|
||||||
# These must be set for fetchdep.sh to get the right branch
|
# These must be set for fetchdep.sh to get the right branch
|
||||||
REPOSITORY: ${{ github.repository }}
|
REPOSITORY: ${{ github.repository }}
|
||||||
PR_NUMBER: ${{ github.event.pull_request.number }}
|
PR_NUMBER: ${{ github.event.pull_request.number }}
|
||||||
|
@ -60,14 +63,15 @@ jobs:
|
||||||
|
|
||||||
- name: Run tests
|
- name: Run tests
|
||||||
run: |
|
run: |
|
||||||
yarn ${{ inputs.disable_coverage != 'true' && 'coverage' || 'test' }} \
|
yarn test \
|
||||||
|
--coverage=${{ env.ENABLE_COVERAGE }} \
|
||||||
--ci \
|
--ci \
|
||||||
--reporters github-actions ${{ steps.metrics.outputs.extra-reporter }} \
|
--reporters github-actions ${{ steps.metrics.outputs.extra-reporter }} \
|
||||||
--max-workers ${{ steps.cpu-cores.outputs.count }} \
|
--max-workers ${{ steps.cpu-cores.outputs.count }} \
|
||||||
--cacheDirectory /tmp/jest_cache
|
--cacheDirectory /tmp/jest_cache
|
||||||
|
|
||||||
- name: Upload Artifact
|
- name: Upload Artifact
|
||||||
if: inputs.disable_coverage != 'true'
|
if: env.ENABLE_COVERAGE == 'true'
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: coverage
|
name: coverage
|
||||||
|
@ -75,6 +79,22 @@ jobs:
|
||||||
coverage
|
coverage
|
||||||
!coverage/lcov-report
|
!coverage/lcov-report
|
||||||
|
|
||||||
|
skip_sonar:
|
||||||
|
name: Skip SonarCloud in merge queue
|
||||||
|
if: github.event_name == 'merge_group' || inputs.disable_coverage == 'true'
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
needs: jest
|
||||||
|
steps:
|
||||||
|
- name: Skip SonarCloud
|
||||||
|
uses: Sibz/github-status-action@faaa4d96fecf273bd762985e0e7f9f933c774918 # v1
|
||||||
|
with:
|
||||||
|
authToken: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
state: success
|
||||||
|
description: SonarCloud skipped
|
||||||
|
context: SonarCloud Code Analysis
|
||||||
|
sha: ${{ github.sha }}
|
||||||
|
target_url: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}
|
||||||
|
|
||||||
app-tests:
|
app-tests:
|
||||||
name: Element Web Integration Tests
|
name: Element Web Integration Tests
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
Loading…
Reference in a new issue