Skip to content

Complete known issues feature #2590

Complete known issues feature

Complete known issues feature #2590

Workflow file for this run

name: Build project
on:
push:
branches: [main]
pull_request:
branches: [main]
permissions:
contents: read
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
lint:
name: Lint
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
with:
node-version: "24.14.x"
cache: "yarn"
- name: Install dependencies
run: yarn install --immutable --immutable-cache --check-cache
- name: Cache build outputs
id: build-cache
uses: actions/cache@v5
with:
path: packages/*/dist
key: build-${{ runner.os }}-${{ runner.arch }}-node-24-${{ hashFiles('yarn.lock', '.yarnrc.yml', '.pnp.cjs', 'package.json', 'tsconfig*.json', 'packages/*/package.json', 'packages/*/tsconfig*.json', 'packages/*/*.d.ts', 'packages/*/.babelrc.*', 'packages/*/rollup.config.*', 'packages/*/webpack.config.*', 'packages/*/postcss.config.*', 'packages/*/src/**', 'packages/*/static/**') }}
- name: Build the project
if: steps.build-cache.outputs.cache-hit != 'true'
run: yarn build
- name: Lint Project
run: yarn lint
- name: Check formatting
run: yarn format:check
# - name: Type-aware lint
# run: yarn lint:type
test:
needs: lint
name: Build on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
with:
node-version: "24.14.x"
cache: "yarn"
- name: Install dependencies
run: yarn install --immutable --immutable-cache --check-cache
- name: Install playwright for static server
run: yarn workspace @allurereport/static-server playwright install chromium
- name: Install playwright for e2e
run: yarn workspace @allurereport/e2e playwright install chromium firefox webkit
- name: Install playwright dependencies for e2e
run: yarn workspace @allurereport/e2e playwright install-deps
- name: Cache build outputs
id: build-cache
uses: actions/cache@v5
with:
path: packages/*/dist
key: build-${{ runner.os }}-${{ runner.arch }}-node-24-${{ hashFiles('yarn.lock', '.yarnrc.yml', '.pnp.cjs', 'package.json', 'tsconfig*.json', 'packages/*/package.json', 'packages/*/tsconfig*.json', 'packages/*/*.d.ts', 'packages/*/.babelrc.*', 'packages/*/rollup.config.*', 'packages/*/webpack.config.*', 'packages/*/postcss.config.*', 'packages/*/src/**', 'packages/*/static/**') }}
- name: Build project
if: steps.build-cache.outputs.cache-hit != 'true'
run: yarn build
- name: Test Project
run: yarn allure run --config=./allurerc.gate.mjs --environment=${{ matrix.os }} --dump=allure-results-${{ matrix.os }} -- yarn test
- name: Upload test results
uses: actions/upload-artifact@v7
if: ${{ !cancelled() }}
with:
name: allure-results-${{ matrix.os }}
path: ./allure-results-${{ matrix.os }}.zip
report:
needs: [lint, test]
name: Build report
runs-on: ubuntu-latest
if: ${{ always() && !cancelled() && contains(fromJSON('["success","failure"]'), needs.test.result) && needs.lint.result != 'failure' }}
permissions:
actions: read
contents: write
pull-requests: write
checks: write
env:
ALLURE_SERVICE_ACCESS_TOKEN: ${{ secrets.ALLURE_SERVICE_ACCESS_TOKEN }}
ALLURE_TOKEN: ${{ secrets.ALLURE_TOKEN }}
ALLURE_PROJECT_ID: ${{ secrets.ALLURE_PROJECT_ID }}
ALLURE_ENDPOINT: ${{ secrets.ALLURE_ENDPOINT }}
ALLURE_LAUNCH_TAGS: "${{ secrets.ALLURE_LAUNCH_TAGS }}, ${{ github.event_name }}"
steps:
- uses: actions/checkout@v6
- uses: actions/setup-node@v6
with:
node-version: "24.14.x"
cache: "yarn"
- name: Download allure results from Ubuntu
uses: actions/download-artifact@v8
continue-on-error: true
with:
name: allure-results-ubuntu-latest
path: ./
- name: Download allure results from macOS
uses: actions/download-artifact@v6
continue-on-error: true
with:
name: allure-results-macos-latest
path: ./
- name: Download allure results from Windows
uses: actions/download-artifact@v8
continue-on-error: true
with:
name: allure-results-windows-latest
path: ./
- name: Install dependencies
run: yarn install --immutable --immutable-cache --check-cache
- name: Cache build outputs
id: build-cache
uses: actions/cache@v5
with:
path: packages/*/dist
key: build-${{ runner.os }}-${{ runner.arch }}-node-24-${{ hashFiles('yarn.lock', '.yarnrc.yml', '.pnp.cjs', 'package.json', 'tsconfig*.json', 'packages/*/package.json', 'packages/*/tsconfig*.json', 'packages/*/*.d.ts', 'packages/*/.babelrc.*', 'packages/*/rollup.config.*', 'packages/*/webpack.config.*', 'packages/*/postcss.config.*', 'packages/*/src/**', 'packages/*/static/**') }}
- name: Build project
if: steps.build-cache.outputs.cache-hit != 'true'
run: yarn build
- name: Generate report
env:
ALLURE_PERF_METRICS: "1"
run: yarn allure generate --config=./allurerc.mjs --dump="allure-results-*.zip" --output=./allure-report
- name: Commit updated quarantine.json
if: ${{ github.event_name == 'push' }}
run: |
if git diff --quiet -- quarantine.json; then
exit 0
fi
git config user.name "${{ vars.ALLURE_CI_APP_SLUG }}[bot]"
git config user.email "${{ vars.ALLURE_CI_APP_USER_ID }}+${{ vars.ALLURE_CI_APP_SLUG }}[bot]@users.noreply.github.com"
git add quarantine.json
git commit -m "Update quarantine.json"
git push origin "HEAD:${GITHUB_REF_NAME}"
- name: Write perf metrics summary
if: ${{ !cancelled() && github.event_name == 'pull_request' }}
run: node ./scripts/allure-perf-summary.mjs ./allure-report/allure-perf-metrics.json --output ./allure-report/allure-perf-metrics.md --github-step-summary
- name: Upload perf metrics
uses: actions/upload-artifact@v7
if: ${{ !cancelled() && github.event_name == 'pull_request' }}
with:
name: allure-perf-metrics
path: |
./allure-report/allure-perf-metrics.json
./allure-report/allure-perf-metrics.md
if-no-files-found: ignore
- name: Allure Report Official
uses: allure-framework/allure-action@v0
with:
report-directory: "./allure-report"
github-token: ${{ secrets.GITHUB_TOKEN }}
perf-metrics-comment:
needs: report
name: Comment perf metrics
runs-on: ubuntu-latest
if: ${{ always() && !cancelled() && needs.report.result == 'success' && github.event_name == 'pull_request' }}
permissions:
actions: read
contents: read
pull-requests: write
steps:
- uses: actions/checkout@v6
- name: Download perf metrics
uses: actions/download-artifact@v6
continue-on-error: true
with:
name: allure-perf-metrics
path: ./allure-perf-metrics
- name: Comment perf metrics on pull request
uses: actions/github-script@v9
with:
script: |
const commentPerfMetrics = require("./scripts/comment-allure-perf-metrics.cjs");
await commentPerfMetrics({ context, github });