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

Upgrade on ember 3.18 #33

Merged
merged 1 commit into from
Jun 17, 2020
Merged
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
167 changes: 74 additions & 93 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,34 +3,25 @@ defaults: &defaults
- image: circleci/node:10-browsers
environment:
JOBS: 1
working_directory: ~/ember-slugify
working_directory: ~/project

orbs:
node: circleci/[email protected]
version: 2.1

version: 2
jobs:
checkout_code:
prepare:
<<: *defaults
steps:
- checkout
- persist_to_workspace:
root: .
paths:
- .

install_dependencies:
<<: *defaults
steps:
- attach_workspace:
at: .
- restore_cache:
keys:
- ember-slugify-node10-v1-{{ checksum "yarn.lock" }}
- node/install-packages:
pkg-manager: "yarn"
cache-key: "yarn.lock"
cache-version: "v1"
include-branch-in-cache-key: false
- run:
name: Yarn Install
command: yarn install --non-interactive --pure-lockfile
- save_cache:
key: ember-slugify-node10-v1-{{ checksum "yarn.lock" }}
paths:
- ~/ember-slugify/node_modules
name: Generate reports folder
command: mkdir reports
- persist_to_workspace:
root: .
paths:
Expand All @@ -41,7 +32,6 @@ jobs:
steps:
- attach_workspace:
at: .
- run: echo 'export PATH=~/ember-slugify/node_modules/.bin:$PATH' >> $BASH_ENV
- run:
name: Lint Handlebars
command: yarn lint:hbs
Expand All @@ -51,90 +41,81 @@ jobs:

test:
<<: *defaults
parameters:
scenario:
type: enum
enum:
[
"lts-3.12",
"lts-3.16",
"release",
"beta",
"canary",
"default",
"default-with-jquery",
"classic",
]
default: "default"
steps:
- attach_workspace:
at: .
- run: echo 'export PATH=~/ember-slugify/node_modules/.bin:$PATH' >> $BASH_ENV
- run:
name: Run Tests
command: yarn test

test_lts_3_4:
<<: *defaults
steps:
- attach_workspace:
at: .
- run: echo 'export PATH=~/ember-slugify/node_modules/.bin:$PATH' >> $BASH_ENV
- run:
name: Run Tests Ember LTS 3.4
command: ember try:one ember-lts-3.4 --skip-cleanup=true

test_release:
<<: *defaults
steps:
- attach_workspace:
at: .
- run: echo 'export PATH=~/ember-slugify/node_modules/.bin:$PATH' >> $BASH_ENV
- run:
name: Run Tests Ember Release
command: ember try:one ember-release --skip-cleanup=true

test_beta:
<<: *defaults
steps:
- attach_workspace:
at: .
- run: echo 'export PATH=~/ember-slugify/node_modules/.bin:$PATH' >> $BASH_ENV
- run:
name: Run Tests Ember Beta
command: ember try:one ember-beta --skip-cleanup=true

test_canary:
<<: *defaults
steps:
- attach_workspace:
at: .
- run: echo 'export PATH=~/ember-slugify/node_modules/.bin:$PATH' >> $BASH_ENV
- run:
name: Run Tests Ember Canary
command: ember try:one ember-canary --skip-cleanup=true

test_default_with_jquery:
<<: *defaults
steps:
- attach_workspace:
at: .
- run: echo 'export PATH=~/ember-slugify/node_modules/.bin:$PATH' >> $BASH_ENV
- run:
name: Run Tests Ember Default With jQuery
command: ember try:one ember-default-with-jquery --skip-cleanup=true
name: Run << parameters.scenario >> Tests
command: yarn ember try:one ember-<< parameters.scenario >> --skip-cleanup=true
- store_test_results:
path: "reports"
- store_artifacts:
path: "reports"

workflows:
version: 2
test_matrix:
jobs:
- checkout_code
- install_dependencies:
requires:
- checkout_code
- prepare
- lint:
requires:
- install_dependencies
- prepare
- test:
requires:
- prepare
- test:
name: test_lts_3_12
scenario: lts-3.12
requires:
- lint
- test
- test:
name: test_lts_3_16
scenario: lts-3.16
requires:
- install_dependencies
- test_lts_3_4:
- lint
- test
- test:
name: test_release
scenario: release
requires:
- install_dependencies
- test_release:
- lint
- test
- test:
name: test_beta
scenario: beta
requires:
- install_dependencies
- test_beta:
- lint
- test
- test:
name: test_canary
scenario: canary
requires:
- install_dependencies
- test_canary:
- lint
- test
- test:
name: test_default_with_jquery
scenario: "default-with-jquery"
requires:
- install_dependencies
- test_default_with_jquery:
- lint
- test
- test:
name: test_classic
scenario: classic
requires:
- install_dependencies
- lint
- test
1 change: 0 additions & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

root = true


[*]
end_of_line = lf
charset = utf-8
Expand Down
12 changes: 10 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
/* eslint-env node */
module.exports = {
root: true,
extends: [
'peopledoc/ember'
'peopledoc/ember-addon'
],

overrides: [
{
files: ['tests/test-helper.js'],
rules: {
'import/no-relative-parent-imports': 0
}
}
]
}
2 changes: 1 addition & 1 deletion .template-lintrc.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
'use strict'

module.exports = {
extends: 'recommended'
extends: 'octane'
}
31 changes: 23 additions & 8 deletions config/ember-try.js
Original file line number Diff line number Diff line change
@@ -1,24 +1,26 @@
'use strict'

const getChannelURL = require('ember-source-channel-url')
const isCI = !!process.env.CI

module.exports = async function() {
return {
command: isCI ? 'ember test --silent --reporter xunit > ./reports/test_results.xml' : 'ember test',
useYarn: true,
scenarios: [
{
name: 'ember-lts-3.4',
name: 'ember-lts-3.12',
npm: {
devDependencies: {
'ember-source': '~3.4.0'
'ember-source': '~3.12.0'
}
}
},
{
name: 'ember-lts-3.8',
name: 'ember-lts-3.16',
npm: {
devDependencies: {
'ember-source': '~3.8.0'
'ember-source': '~3.16.0'
}
}
},
Expand Down Expand Up @@ -46,10 +48,6 @@ module.exports = async function() {
}
}
},
// The default `.travis.yml` runs this scenario via `npm test`,
// not via `ember try`. It's still included here so that running
// `ember try:each` manually or from a customized CI config will run it
// along with all the other scenarios.
{
name: 'ember-default',
npm: {
Expand All @@ -63,11 +61,28 @@ module.exports = async function() {
'jquery-integration': true
})
},

npm: {
devDependencies: {
'@ember/jquery': '^0.5.1'
}
}
},
{
name: 'ember-classic',
env: {
EMBER_OPTIONAL_FEATURES: JSON.stringify({
'application-template-wrapper': true,
'default-async-observers': false,
'template-only-glimmer-components': false
})
},

npm: {
ember: {
edition: 'classic'
}
}
}
]
}
Expand Down
59 changes: 33 additions & 26 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,50 +18,57 @@
"test": "tests"
},
"scripts": {
"build": "ember build",
"build": "ember build --environment=production",
"lint": "npm-run-all --aggregate-output --continue-on-error --parallel lint:*",
"lint:hbs": "ember-template-lint .",
"lint:js": "eslint .",
"start": "ember serve",
"test": "ember test",
"test:all": "ember try:each",
"test": "npm-run-all lint:* test:*",
"test:ember": "ember test",
"test:ember-compatibility": "ember try:each",
"prettier:js": "prettier-eslint --write --single-quote {addon,app,config,lib,server,tests}/{**/,}*.js"
},
"dependencies": {
"ember-auto-import": "^1.2.19",
"ember-cli-babel": "^7.7.3",
"ember-cli-htmlbars": "^3.0.1",
"ember-auto-import": "^1.5.3",
"ember-cli-babel": "^7.19.0",
"ember-cli-htmlbars": "^4.3.1",
"simple-pinyin": "^3.0.2",
"speakingurl": "^14.0.1",
"unorm": "^1.5.0"
},
"devDependencies": {
"@ember/optional-features": "^0.7.0",
"babel-eslint": "^10.0.3",
"@ember/optional-features": "^1.3.0",
"@glimmer/component": "^1.0.0",
"@glimmer/tracking": "^1.0.0",
"babel-eslint": "^10.1.0",
"broccoli-asset-rev": "^3.0.0",
"ember-circleci": "^1.2.0",
"ember-cli": "~3.12.1",
"ember-cli-dependency-checker": "^3.1.0",
"ember-cli-eslint": "^5.1.0",
"ember-cli-htmlbars-inline-precompile": "^2.1.0",
"ember-cli-inject-live-reload": "^1.8.2",
"ember-circleci": "^1.9.0",
"ember-cli": "~3.18.0",
"ember-cli-dependency-checker": "^3.2.0",
"ember-cli-inject-live-reload": "^2.0.2",
"ember-cli-sri": "^2.1.1",
"ember-cli-template-lint": "^1.0.0-beta.1",
"ember-cli-uglify": "^2.1.0",
"ember-cli-uglify": "^3.0.0",
"ember-disable-prototype-extensions": "^1.1.3",
"ember-export-application-global": "^2.0.0",
"ember-load-initializers": "^2.0.0",
"ember-export-application-global": "^2.0.1",
"ember-load-initializers": "^2.1.1",
"ember-maybe-import-regenerator": "^0.1.6",
"ember-qunit": "^4.4.1",
"ember-resolver": "^5.0.1",
"ember-source": "~3.12.1",
"ember-source-channel-url": "^1.1.0",
"ember-try": "^1.0.0",
"eslint-config-peopledoc": "^1.7.2",
"ember-qunit": "^4.6.0",
"ember-resolver": "^8.0.0",
"ember-source": "~3.18.0",
"ember-source-channel-url": "^2.0.1",
"ember-template-lint": "^2.6.0",
"ember-try": "^1.4.0",
"eslint": "^6.8.0",
"eslint-config-peopledoc": "^2.0.1",
"loader.js": "^4.7.0",
"qunit-dom": "^0.8.4"
"npm-run-all": "^4.1.5",
"qunit-dom": "^1.2.0"
},
"engines": {
"node": "8.* || >= 10.*"
"node": "10.* || >= 12"
},
"ember": {
"edition": "octane"
},
"ember-addon": {
"configPath": "tests/dummy/config"
Expand Down
Loading