Skip to content

⚙️ config(ci): Run ci:test:deploy on workflow_run trigger. #3475

⚙️ config(ci): Run ci:test:deploy on workflow_run trigger.

⚙️ config(ci): Run ci:test:deploy on workflow_run trigger. #3475

Workflow file for this run

name: ci:test
on:
push:
branches:
- main
pull_request:
merge_group:
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
test:
name: Continuous integration (tests)
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout 🛎️
uses: actions/checkout@v4
- name: Cache ~/.cache/puppeteer 🎭
uses: actions/cache@v4
id: cache-puppeteer
env:
cache-name: cache-puppeteer
with:
path: ~/.cache/puppeteer
key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
- name: Install 💾
uses: ./.github/actions/install
- name: Cache build 💽
uses: meteor-actions/cache-build@v4
with:
key: test
- name: Tests 🔬
run: meteor npm run ci:test
- name: Archive coverage data 💽
uses: actions/upload-artifact@v4
with:
name: test-coverage
path: .coverage
retention-days: 1
test-coverage-upload:
name: Continuous integration (upload tests coverage)
needs:
- test
runs-on: ubuntu-latest
timeout-minutes: 1
steps:
- name: Load coverage data 💽
uses: actions/download-artifact@v4
with:
name: test-coverage
path: .coverage
- name: Publish coverage report 📰
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
flags: test
directory: ./.coverage/
fail_ci_if_error: true
test-app:
name: Continuous integration (app tests)
runs-on: ubuntu-latest
timeout-minutes: 20
steps:
- name: Checkout 🛎️
uses: actions/checkout@v4
- name: Cache ~/.cache/puppeteer 🎭
uses: actions/cache@v4
id: cache-puppeteer
env:
cache-name: cache-puppeteer
with:
path: ~/.cache/puppeteer
key: ${{ runner.os }}-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
- name: Install 💾
uses: ./.github/actions/install
- name: Cache build 💽
uses: meteor-actions/cache-build@v4
with:
key: test-app
- name: App Tests 🕹️
run: meteor npm run ci:test -- --full-app
- name: Archive coverage data 💽
uses: actions/upload-artifact@v4
with:
name: test-app-coverage
path: .coverage
retention-days: 1
test-app-coverage-upload:
name: Continuous integration (upload app tests coverage)
needs:
- test-app
runs-on: ubuntu-latest
timeout-minutes: 1
steps:
- name: Load coverage data 💽
uses: actions/download-artifact@v4
with:
name: test-app-coverage
path: .coverage
- name: Publish coverage report 📰
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
flags: test-app
directory: ./.coverage/
fail_ci_if_error: true