add workflows

This commit is contained in:
mahula 2024-02-22 11:53:42 +01:00
parent 0ba182a89f
commit cbd8956953
5 changed files with 109 additions and 0 deletions

7
.github/file-filters.yml vendored Normal file
View File

@ -0,0 +1,7 @@
# These file filter patterns are used by the action https://github.com/dorny/paths-filter
e2e-all:
- '**/*'
e2e-docs:
- '**/*.md'
- '.vuepress/*'

24
.github/workflows/e2e.deploy.docs.yml vendored Normal file
View File

@ -0,0 +1,24 @@
name: e2e:deploy:docs to github
on:
push:
branches:
- master
jobs:
build-and-deploy:
name: Deploy Docs - E2E Testing
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@master
- name: vuepress-deploy
uses: jenkey2011/vuepress-deploy@master
env:
ACCESS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
#TARGET_REPO: username/repo
#TARGET_BRANCH: master
BUILD_SCRIPT: npm install && npm run docs:build
BUILD_DIR: build/docs/
VUEPRESS_BASE: boilerplate-e2e-cypress-cucumber

14
.github/workflows/e2e.run.tests.yml vendored Normal file
View File

@ -0,0 +1,14 @@
name: e2e:run:tests
on: push
jobs:
e2e-tests:
name: Run all E2E tests
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@master
- name: E2E - Run all tests
uses: cypress-io/github-action@v6

View File

@ -0,0 +1,32 @@
name: e2e:test:build test docs
on: push
jobs:
files-changed:
name: Detect File Changes
runs-on: ubuntu-latest
outputs:
changes: ${{ steps.changes.outputs.e2e-docs }}
steps:
- uses: actions/checkout@master
- name: Check for e2e docs file changes
uses: dorny/paths-filter@v3.0.1
id: changes
with:
token: ${{ github.token }}
filters: .github/file-filters.yml
list-files: shell
build:
if: needs.files-changed.outputs.changes == 'true'
name: Build Docs - E2E Testing
needs: files-changed
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@master
- name: E2E Testing | Build Docs
run: npm install && npm run docs:build

32
.github/workflows/e2e.test.lint.yml vendored Normal file
View File

@ -0,0 +1,32 @@
name: e2e:test:lint code with defined linters
on: push
jobs:
files-changed:
name: Detect File Changes
runs-on: ubuntu-latest
outputs:
changes: ${{ steps.changes.outputs.e2e-all }}
steps:
- uses: actions/checkout@master
- name: Check for frontend file changes
uses: dorny/paths-filter@v3.0.1
id: changes
with:
token: ${{ github.token }}
filters: .github/file-filters.yml
list-files: shell
lint:
if: needs.files-changed.outputs.changes == 'true'
name: Lint - E2E files
needs: files-changed
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@master
- name: E2E files | Lint
run: npm install && npm run test:lint