Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Ignore] Testing CI/CD #1146

Open
wants to merge 9 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: ci

on:
push:
branches:
- develop
- 4.1-develop
pull_request:
branches:
- develop
- 4.1-develop

jobs:
ci:
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [ ubuntu-latest ]
node: [ 14 ]

steps:
- name: Checkout 🛎
uses: actions/checkout@master

- name: Setup node env 🏗
uses: actions/[email protected]
with:
node-version: ${{ matrix.node }}
check-latest: true
cache: 'npm'

- name: Install dependencies 👨🏻‍💻
run: npm ci

- name: Run linter 👀
run: npm run lint

# - name: Run tests 🧪
# run: npm run test

- name: Cypress run
uses: cypress-io/github-action@v1
with:
start: npm run serve
wait-on: http://localhost:8080/
config_file: cypress.json
spec: "tests/e2e/**/*"

- name: Run build bundle 📦
run: npm run build-bundle
20 changes: 10 additions & 10 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

23 changes: 12 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,22 +5,14 @@
"serve": "vue-cli-service serve",
"build": "vue-cli-service build",
"test:unit": "vue-cli-service test:unit",
"test:e2e": "vue-cli-service test:e2e",
"lint": "vue-cli-service lint --no-fix",
"build-bundle": "vue-cli-service build --target lib --name vue-form-builder ./src/components/index.js",
"lint-fix": "vue-cli-service lint",
"open-cypress": "TZ=UTC nyc cypress open",
"run-cypress": "TZ=UTC nyc cypress run",
"test": "vue-cli-service test:unit"
},
"nyc": {
"include": [
"src/**"
],
"extension": [
".js",
".vue"
]
},
"main": "./dist/vue-form-builder.common.js",
"files": [
"dist/*",
Expand All @@ -47,7 +39,7 @@
"@processmaker/vue-form-elements": "0.28.2",
"@processmaker/vue-multiselect": "^2.2.0",
"@vue/cli-plugin-babel": "^3.6.0",
"@vue/cli-plugin-e2e-cypress": "^4.0.3",
"@vue/cli-plugin-e2e-cypress": "^4.5.15",
"@vue/cli-plugin-eslint": "^3.6.0",
"@vue/cli-plugin-unit-jest": "^4.3.0",
"@vue/cli-service": "^3.6.0",
Expand Down Expand Up @@ -99,5 +91,14 @@
"> 1%",
"last 2 versions",
"not ie <= 8"
]
],
"nyc": {
"include": [
"src/**"
],
"extension": [
".js",
".vue"
]
}
}
2 changes: 1 addition & 1 deletion tests/e2e/support/commands.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import '@4tw/cypress-drag-drop';
import { set } from 'lodash';
import set from 'lodash/set';
import 'cypress-wait-until';

Cypress.Commands.add('setPreviewDataInput', (input) => {
Expand Down