Skip to content

Commit

Permalink
Disable Ember.js v4 scenarios, use npm in GH actions and make CI pass
Browse files Browse the repository at this point in the history
  • Loading branch information
SergeAstapov committed Oct 27, 2021
1 parent 1568f47 commit 101d00d
Show file tree
Hide file tree
Showing 4 changed files with 3,619 additions and 6,909 deletions.
116 changes: 56 additions & 60 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,76 +3,72 @@ name: CI
on:
push:
branches:
- main
- master
pull_request: {}

jobs:

lint:
name: "Lint"
env:
CI: true
test:
name: "Tests"
runs-on: ubuntu-latest
strategy:
fail-fast: true
steps:
- uses: actions/checkout@v2
- name: Install node
uses: actions/setup-node@v2-beta
with:
node-version: 12.x

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"

- uses: actions/cache@v2
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: yarn install
run: yarn
- name: lint
run: yarn lint:js
steps:
- uses: actions/checkout@v2
- name: Install Node
uses: actions/setup-node@v2
with:
node-version: 12.x
cache: npm
- name: Install Dependencies
run: npm ci
- name: Lint
run: npm run lint
- name: Run Tests
run: npm run test:ember

floating:
name: "Floating dependencies"
env:
CI: true
name: "Floating Dependencies"
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
try-scenario: [
ember-lts-3.12,
ember-lts-3.16,
ember-lts-3.20,
ember-release,
ember-beta,
embroider-safe,
embroider-optimized,
]

steps:
- uses: actions/checkout@v2
- name: Install node
uses: actions/setup-node@v2-beta
with:
node-version: 12.x
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: 12.x
cache: npm
- name: Install Dependencies
run: npm install --no-shrinkwrap
- name: Run Tests
run: npm run test:ember

- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
try-scenarios:
name: ${{ matrix.try-scenario }}
runs-on: ubuntu-latest
needs: 'test'

- uses: actions/cache@v2
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: yarn install
run: yarn
- name: test
run: ./node_modules/.bin/ember try:one ${{ matrix.try-scenario }}
strategy:
fail-fast: false
matrix:
try-scenario:
- ember-lts-3.16
- ember-lts-3.20
- ember-lts-3.24
- ember-release
#- ember-beta
#- ember-canary
- ember-classic
- ember-default-with-jquery
- embroider-safe
- embroider-optimized

steps:
- uses: actions/checkout@v2
- name: Install Node
uses: actions/setup-node@v2
with:
node-version: 12.x
cache: npm
- name: Install Dependencies
run: npm ci
- name: Run Tests
run: ./node_modules/.bin/ember try:one ${{ matrix.try-scenario }}
16 changes: 9 additions & 7 deletions config/ember-try.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,29 +5,28 @@ const { embroiderSafe, embroiderOptimized } = require('@embroider/test-setup');

module.exports = async function () {
return {
useYarn: true,
scenarios: [
{
name: 'ember-lts-3.12',
name: 'ember-lts-3.16',
npm: {
devDependencies: {
'ember-source': '~3.12.0',
'ember-source': '~3.16.0',
},
},
},
{
name: 'ember-lts-3.16',
name: 'ember-lts-3.20',
npm: {
devDependencies: {
'ember-source': '~3.16.0',
'ember-source': '~3.20.5',
},
},
},
{
name: 'ember-lts-3.20',
name: 'ember-lts-3.24',
npm: {
devDependencies: {
'ember-source': '~3.20.5',
'ember-source': '~3.24.0',
},
},
},
Expand Down Expand Up @@ -78,6 +77,9 @@ module.exports = async function () {
}),
},
npm: {
devDependencies: {
'ember-source': '~3.28.4',
},
ember: {
edition: 'classic',
},
Expand Down
Loading

0 comments on commit 101d00d

Please sign in to comment.