Skip to content

Commit

Permalink
Adding github action tests (#769)
Browse files Browse the repository at this point in the history
  • Loading branch information
kiwiupover authored Jul 24, 2020
1 parent db47968 commit 1d5bb8f
Show file tree
Hide file tree
Showing 3 changed files with 1,847 additions and 1,514 deletions.
66 changes: 66 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
name: CI

on:
pull_request:
push:
# Filtering branches here prevents duplicate builds from pull_request and push
branches:
- master
- beta
- 'v*'
- /^greenkeeper.*$/

# Always run CI for tags
tags:
- '*'

# Early issue detection: run CI weekly on Sundays
schedule:
- cron: '0 6 * * 0'

jobs:
test-mocha:
name: Mocha Tests - ${{ matrix.node-version }}
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [12.x, 10.x]

steps:
- name: Checkout Code
uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install NPM version 4
run: |
npm config set spin false
npm install -g npm@4
- name: Yarn Install
run: yarn install --ignore-engines
- name: Run Mocha Tests
run: yarn test:mocha

test-ember:
name: Ember Tests
runs-on: ${{ matrix.os }}

strategy:
matrix:
node-version: [12.x, 10.x]
os: [ubuntu-latest, windows-latest]

steps:
- name: Checkout Code
uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Yarn Install
run: yarn install --ignore-engines
- name: Run Tests
run: yarn test:ember

2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@
"release": "release-it",
"start": "ember serve",
"test": "mocha && ember test",
"test:mocha": "mocha",
"test:ember": "ember test",
"test:precook": "node node_modules/ember-cli-addon-tests/scripts/precook-node-modules.js"
},
"dependencies": {
Expand Down
Loading

0 comments on commit 1d5bb8f

Please sign in to comment.