Skip to content

Merge pull request #588 from catho/QTM-786 #278

Merge pull request #588 from catho/QTM-786

Merge pull request #588 from catho/QTM-786 #278

name: Quantum CI - publish
on:
push:
branches:
- master
- beta
jobs:
tests:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
- name: Setup node
uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
- name: Install the dependencies
run: yarn
- name: Run storybook
run: yarn storybook --smoke-test
- name: Run unit tests
run: yarn test:components
- name: Run the regression tests
run: yarn build:regression
publish:
needs: tests
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
- name: Setup node
uses: actions/setup-node@v4
with:
node-version-file: '.nvmrc'
- name: Install the dependencies
run: yarn
- name: Build
run: yarn build
- name: Setting NPM token
run: ./scripts/publish.sh
env:
NPM_TOKEN: ${{secrets.NPM_TOKEN}}
- name: Publish package
run: yarn semantic-release
env:
NPM_TOKEN: ${{secrets.NPM_TOKEN}}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_URL: 'https://api.github.com/'
- name: Deploy storybook to Github Pages
if: ${{ github.ref == 'refs/heads/master' }}
run: yarn deploy-storybook -- --ci
env:
GH_TOKEN: catho:${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}