Skip to content

Commit

Permalink
Merge pull request #21 from supersabillon/upgrade-2-14
Browse files Browse the repository at this point in the history
Upgrade to ember-cli 2.14
  • Loading branch information
supersabillon authored Jul 20, 2017
2 parents a4a2bd3 + a6ed28f commit 3ff6ae9
Show file tree
Hide file tree
Showing 17 changed files with 80 additions and 47 deletions.
13 changes: 13 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
module.exports = {
root: true,
parserOptions: {
ecmaVersion: 2017,
sourceType: 'module'
},
extends: 'eslint:recommended',
env: {
browser: true
},
rules: {
}
};
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,10 @@
/coverage/*
/libpeerconnection.log
npm-debug.log*
yarn-error.log
testem.log

# ember-try
.node_modules.ember-try/
bower.json.ember-try
package.json.ember-try
2 changes: 1 addition & 1 deletion .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
.editorconfig
.ember-cli
.gitignore
.jshintrc
.eslintrc.js
.watchmanconfig
.travis.yml
bower.json
Expand Down
1 change: 1 addition & 0 deletions addon/components/ag-grid.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/*global agGrid*/
import Ember from 'ember';
import config from 'ember-get-config';

Expand Down
2 changes: 1 addition & 1 deletion config/ember-try.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*jshint node:true*/
/* eslint-env node */
module.exports = {
scenarios: [
{
Expand Down
4 changes: 2 additions & 2 deletions config/environment.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
/*jshint node:true*/
/* eslint-env node */
'use strict';

module.exports = function(/* environment, appConfig */) {
return {
// agGrid: {
// useEnterprise: true
// }
};
};
};
9 changes: 5 additions & 4 deletions ember-cli-build.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
/*jshint node:true*/
/* global require, module */
var EmberAddon = require('ember-cli/lib/broccoli/ember-addon');
/* eslint-env node */
'use strict';

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

module.exports = function(defaults) {
var app = new EmberAddon(defaults, {
let app = new EmberAddon(defaults, {
// Add options here
});

Expand Down
33 changes: 15 additions & 18 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ember-ag-grid",
"version": "0.4.0",
"version": "0.4.1",
"description": "An ag-Grid component for ember cli",
"keywords": [
"ember-addon",
Expand All @@ -23,36 +23,33 @@
},
"dependencies": {
"ember-get-config": "0.0.4",
"ember-cli-babel": "^5.1.7"
"ember-cli-babel": "^6.3.0"
},
"devDependencies": {
"broccoli-asset-rev": "^2.4.5",
"ember-ajax": "^2.4.1",
"ember-ajax": "^3.0.0",
"ember-bootstrap": "0.6.4",
"ember-cli": "2.11.0",
"ember-cli": "~2.14.0",
"ember-cli-app-version": "^2.0.0",
"ember-cli-dependency-checker": "^1.3.0",
"ember-cli-htmlbars": "^1.1.1",
"ember-cli-htmlbars-inline-precompile": "^0.3.3",
"ember-cli-eslint": "^3.0.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-jshint": "^2.0.1",
"ember-cli-mirage": "0.1.11",
"ember-cli-qunit": "^3.0.1",
"ember-cli-release": "^0.2.9",
"ember-cli-shims": "^1.0.2",
"ember-cli-qunit": "^4.0.0",
"ember-cli-shims": "^1.1.0",
"ember-cli-sri": "^2.1.0",
"ember-cli-test-loader": "^1.1.0",
"ember-cli-uglify": "^1.2.0",
"ember-data": "^2.11.0",
"ember-disable-prototype-extensions": "^1.1.0",
"ember-export-application-global": "^1.0.5",
"ember-load-initializers": "^0.6.0",
"ember-resolver": "^2.0.3",
"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.11.0",
"loader.js": "^4.0.10"
"loader.js": "^4.2.3"
},
"engines": {
"node": ">= 0.12.0"
"node": "^4.5 || 6.* || >= 7.*"
},
"ember-addon": {
"configPath": "tests/dummy/config"
Expand Down
17 changes: 8 additions & 9 deletions testem.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
/*jshint node:true*/
/* eslint-env node */
module.exports = {
"framework": "qunit",
"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: [
'PhantomJS'
],
"launch_in_dev": [
"PhantomJS",
"Chrome"
launch_in_dev: [
'PhantomJS',
'Chrome'
]
};
5 changes: 5 additions & 0 deletions tests/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module.exports = {
env: {
embertest: true
}
};
2 changes: 2 additions & 0 deletions tests/dummy/app/components/pagination-grid.js
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,9 @@ export default Component.extend({
// this code should contact the server for rows. however for the purposes of the demo,
// the data is generated locally, a timer is used to give the experience of
// an asynchronous call
/* eslint-disable no-console */
console.log('asking for ' + params.startRow + ' to ' + params.endRow);
/* eslint-enable no-console */
setTimeout( function() {
// take a chunk of the array, matching the start and finish times
let rowsThisPage = data.slice(params.startRow, params.endRow);
Expand Down
2 changes: 1 addition & 1 deletion tests/dummy/app/templates/components/simple-grid.hbs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<section class="example">
<h3>10 records</h3>
{{ag-grid gridOptions=gridOptions width="background-color:blue"}}
{{ag-grid gridOptions=gridOptions width="500px"}}
</section>

7 changes: 4 additions & 3 deletions tests/dummy/config/environment.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
/* jshint node: true */
/* eslint-env node */
'use strict';

module.exports = function(environment) {
var ENV = {
let ENV = {
modulePrefix: 'dummy',
environment: environment,
environment,
rootURL: '/',
locationType: 'auto',
EmberENV: {
Expand Down
9 changes: 9 additions & 0 deletions tests/dummy/config/targets.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
/* eslint-env node */
module.exports = {
browsers: [
'ie 9',
'last 1 Chrome versions',
'last 1 Firefox versions',
'last 1 Safari versions'
]
};
4 changes: 2 additions & 2 deletions tests/helpers/module-for-acceptance.js
Original file line number Diff line number Diff line change
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));
}
});
}
9 changes: 3 additions & 6 deletions tests/helpers/start-app.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,13 @@ import Application from '../../app';
import config from '../../config/environment';

export default function startApp(attrs) {
let application;

let attributes = Ember.merge({}, config.APP);
attributes = Ember.merge(attributes, attrs); // use defaults, but you can override;

Ember.run(() => {
application = Application.create(attributes);
return Ember.run(() => {
let application = Application.create(attributes);
application.setupForTesting();
application.injectTestHelpers();
return application;
});

return application;
}
2 changes: 2 additions & 0 deletions tests/test-helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,7 @@ import resolver from './helpers/resolver';
import {
setResolver
} from 'ember-qunit';
import { start } from 'ember-cli-qunit';

setResolver(resolver);
start();

0 comments on commit 3ff6ae9

Please sign in to comment.