Skip to content

Commit

Permalink
Latest Ember CLI, Chrome Testing, yarn.lock
Browse files Browse the repository at this point in the history
  - Ember CLI [v2.14.1](https://github.com/ember-cli/ember-cli/releases/tag/v2.14.1)
  - Swapping PhantomJS -> [Chrome headless testing in Dev and CI](https://embermap.com/notes/59-ember-tests-with-headless-chrome)
  - Adding yarn.lock file for deterministing builds using [Yarn](https://yarnpkg.com/en/)
  • Loading branch information
alexdiliberto committed Aug 2, 2017
1 parent 7377e9a commit 2499285
Show file tree
Hide file tree
Showing 12 changed files with 5,777 additions and 38 deletions.
10 changes: 8 additions & 2 deletions .gitignore
@@ -1,4 +1,4 @@
# See http://help.github.com/ignore-files/ for more about ignoring files.
# See https://help.github.com/ignore-files/ for more about ignoring files.

# compiled output
/lib
Expand All @@ -15,7 +15,13 @@
/connect.lock
/coverage/*
/libpeerconnection.log
npm-debug.log
npm-debug.log*
yarn-error.log
testem.log
project.sublime-project
project.sublime-workspace

# ember-try
.node_modules.ember-try/
bower.json.ember-try
package.json.ember-try
2 changes: 1 addition & 1 deletion .npmignore
Expand Up @@ -8,7 +8,7 @@
.editorconfig
.ember-cli
.gitignore
.jshintrc
.eslintrc.js
.watchmanconfig
.travis.yml
bower.json
Expand Down
25 changes: 17 additions & 8 deletions .travis.yml
@@ -1,23 +1,32 @@
---
language: node_js
node_js:
# we recommend testing addons with the same minimum supported node version as Ember CLI
# so that your addon works for all apps
- "4"

sudo: false
dist: trusty

addons:
chrome: stable

cache:
directories:
- node_modules
yarn: true

matrix:
fast_finish: true

before_install:
- npm config set spin false
- npm install phantomjs-prebuilt
- phantomjs --version
- curl -o- -L https://yarnpkg.com/install.sh | bash
- export PATH=$HOME/.yarn/bin:$PATH

install:
- npm install
- yarn install --no-lockfile --non-interactive

script:
- npm run lint
- npm run nodetest
- yarn lint
- yarn nodetest
# Usually, it's ok to finish the test scenario without reverting
# to the addon's original dependency state, skipping "cleanup".
- ember try:each --skip-cleanup
5 changes: 3 additions & 2 deletions README.md
Expand Up @@ -127,7 +127,8 @@ A: `Yes, it can import SVGs from any directory defined in the sourceDirs array.`

### Installation

* `git clone git@github.com:ivanvotti/ember-svg-jar.git`
* `git clone <repository-url>` this repository
* `cd ember-svg-jar`
* `npm install`

### Building
Expand Down Expand Up @@ -165,7 +166,7 @@ npm run lint
* `ember serve`
* Visit the app at [http://localhost:4200](http://localhost:4200)

For more information on using ember-cli, visit [http://www.ember-cli.com/](http://www.ember-cli.com/).
For more information on using ember-cli, visit [https://ember-cli.com/](https://ember-cli.com/).

## Asset viewer

Expand Down
2 changes: 1 addition & 1 deletion ember-cli-build.js
@@ -1,5 +1,5 @@
/* eslint-env node */
'use strict';
'use-strict';

const EmberAddon = require('ember-cli/lib/broccoli/ember-addon');

Expand Down
17 changes: 8 additions & 9 deletions package.json
Expand Up @@ -5,8 +5,8 @@
"keywords": [
"ember-addon"
],
"author": "Ivan Votti <ivanvotti@gmail.com>",
"license": "MIT",
"author": "Ivan Votti <ivanvotti@gmail.com>",
"directories": {
"doc": "doc",
"test": "tests"
Expand Down Expand Up @@ -35,7 +35,7 @@
"broccoli-svg-optimizer": "^1.0.2",
"broccoli-symbolizer": "^0.5.0",
"cheerio": "^0.20.0",
"ember-cli-babel": "^6.0.0",
"ember-cli-babel": "^6.3.0",
"lodash": "^4.13.1",
"mkdirp": "^0.5.1",
"path-posix": "^1.0.0"
Expand All @@ -48,22 +48,21 @@
"chai": "^3.5.0",
"chai-as-promised": "^5.3.0",
"ember-ajax": "^3.0.0",
"ember-cli": "2.13.1",
"ember-cli": "~2.14.1",
"ember-cli-dependency-checker": "^1.3.0",
"ember-cli-eslint": "^3.0.0",
"ember-cli-htmlbars": "^1.1.1",
"ember-cli-htmlbars-inline-precompile": "^0.4.0",
"ember-cli-htmlbars": "^2.0.1",
"ember-cli-htmlbars-inline-precompile": "^0.4.3",
"ember-cli-inject-live-reload": "^1.4.1",
"ember-cli-qunit": "^4.0.0",
"ember-cli-release": "^1.0.0-beta.2",
"ember-cli-shims": "^1.1.0",
"ember-cli-sri": "^2.1.0",
"ember-cli-uglify": "^1.2.0",
"ember-disable-prototype-extensions": "^1.1.0",
"ember-disable-prototype-extensions": "^1.1.2",
"ember-export-application-global": "^2.0.0",
"ember-load-initializers": "^1.0.0",
"ember-resolver": "^4.0.0",
"ember-source": "~2.13.0",
"ember-source": "~2.14.1",
"eslint-config-airbnb-base": "^5.0.0",
"eslint-plugin-import": "^1.12.0",
"glob": "^7.0.5",
Expand All @@ -73,7 +72,7 @@
"rimraf": "^2.5.4"
},
"engines": {
"node": ">= 4"
"node": "^4.5 || 6.* || >= 7.*"
},
"ember-addon": {
"configPath": "tests/dummy/config",
Expand Down
23 changes: 15 additions & 8 deletions testem.js
@@ -1,12 +1,19 @@
/* eslint-env node */
module.exports = {
"test_page": "tests/index.html?hidepassed",
"disable_watching": true,
"launch_in_ci": [
"PhantomJS"
test_page: 'tests/index.html?hidepassed',
disable_watching: true,
launch_in_ci: [
'Chrome'
],
"launch_in_dev": [
"PhantomJS",
"Chrome"
]
launch_in_dev: [
'Chrome'
],
browser_args: {
Chrome: [
'--disable-gpu',
'--headless',
'--remote-debugging-port=9222',
'--window-size=1440,900'
]
}
};
2 changes: 0 additions & 2 deletions tests/dummy/app/app.js
Expand Up @@ -3,8 +3,6 @@ import loadInitializers from 'ember-load-initializers';
import Resolver from './resolver';
import config from './config/environment';

Ember.MODEL_FACTORY_INJECTIONS = true;

const App = Ember.Application.extend({
modulePrefix: config.modulePrefix,
podModulePrefix: config.podModulePrefix,
Expand Down
5 changes: 3 additions & 2 deletions tests/dummy/config/environment.js
@@ -1,9 +1,10 @@
/* eslint-env node */
'use strict';

module.exports = function(environment) {
var ENV = {
let ENV = {
modulePrefix: 'dummy',
environment: environment,
environment,
rootURL: '/',
locationType: 'auto',
EmberENV: {
Expand Down
1 change: 0 additions & 1 deletion tests/dummy/config/targets.js
@@ -1,5 +1,4 @@
/* eslint-env node */

module.exports = {
browsers: [
'ie 9',
Expand Down
4 changes: 2 additions & 2 deletions tests/helpers/module-for-acceptance.js
Expand Up @@ -3,7 +3,7 @@ import Ember from 'ember';
import startApp from '../helpers/start-app';
import destroyApp from '../helpers/destroy-app';

const { RSVP: { Promise } } = Ember;
const { RSVP: { resolve } } = Ember;

export default function(name, options = {}) {
module(name, {
Expand All @@ -17,7 +17,7 @@ export default function(name, options = {}) {

afterEach() {
let afterEach = options.afterEach && options.afterEach.apply(this, arguments);
return Promise.resolve(afterEach).then(() => destroyApp(this.application));
return resolve(afterEach).then(() => destroyApp(this.application));
}
});
}

0 comments on commit 2499285

Please sign in to comment.