Fix tests

This commit is contained in:
Basti 2017-11-08 23:35:23 +01:00
parent 3956a59f58
commit bf84e70527
7 changed files with 15 additions and 30 deletions

View File

@ -44,7 +44,7 @@ linters:
style: same_line # or 'new_line' style: same_line # or 'new_line'
EmptyLineBetweenBlocks: EmptyLineBetweenBlocks:
enabled: true enabled: false
ignore_single_line_blocks: true ignore_single_line_blocks: true
EmptyRule: EmptyRule:
@ -86,7 +86,7 @@ linters:
width: 2 width: 2
LeadingZero: LeadingZero:
enabled: true enabled: false
style: exclude_zero # or 'include_zero' style: exclude_zero # or 'include_zero'
MergeableSelector: MergeableSelector:
@ -100,7 +100,7 @@ linters:
NestingDepth: NestingDepth:
enabled: true enabled: true
max_depth: 3 max_depth: 5
ignore_parent_selectors: false ignore_parent_selectors: false
PlaceholderInExtend: PlaceholderInExtend:
@ -116,7 +116,7 @@ linters:
max_properties: 10 max_properties: 10
PropertySortOrder: PropertySortOrder:
enabled: true enabled: false
ignore_unspecified: false ignore_unspecified: false
min_properties: 2 min_properties: 2
separate_groups: false separate_groups: false
@ -151,7 +151,7 @@ linters:
SelectorDepth: SelectorDepth:
enabled: true enabled: true
max_depth: 3 max_depth: 5
SelectorFormat: SelectorFormat:
enabled: true enabled: true

View File

@ -1,7 +1,7 @@
import Controller from '@ember/controller'; import Controller from '@ember/controller';
import { inject as service } from '@ember/service'; import { inject as service } from '@ember/service';
import { alias } from '@ember/object/computed'; import { alias } from '@ember/object/computed';
import { observer, computed } from '@ember/object'; import { observer } from '@ember/object';
export default Controller.extend({ export default Controller.extend({
@ -26,5 +26,4 @@ export default Controller.extend({
}); });
} }
}); });

View File

@ -4,8 +4,8 @@
#remotestorage-widget { #remotestorage-widget {
position: fixed; position: fixed;
top: 0.5rem;
right: 0.5rem; right: 0.5rem;
top: 0.5rem;
} }
#app-container { #app-container {
@ -22,8 +22,8 @@
> aside { > aside {
flex: 0 0 16rem; flex: 0 0 16rem;
padding: 2rem;
overflow: auto; overflow: auto;
padding: 2rem;
nav { nav {
ul { ul {
@ -40,7 +40,7 @@
> main { > main {
flex: 1; flex: 1;
padding: 2rem;
overflow: auto; overflow: auto;
padding: 2rem;
} }
} }

View File

@ -6,19 +6,9 @@ moduleForComponent('categories-nav', 'Integration | Component | categories nav',
}); });
test('it renders', function(assert) { test('it renders', function(assert) {
// Set any properties with this.set('myProperty', 'value'); this.set('categories', [ 'documents', 'notes' ]);
// Handle any actions with this.on('myAction', function(val) { ... });
this.render(hbs`{{categories-nav}}`); this.render(hbs`{{categories-nav categories=categories}}`);
assert.equal(this.$().text().trim(), ''); assert.equal(this.$('ul li:first a').text(), 'documents');
// Template block usage:
this.render(hbs`
{{#categories-nav}}
template block text
{{/categories-nav}}
`);
assert.equal(this.$().text().trim(), 'template block text');
}); });

View File

@ -1,11 +1,9 @@
import { moduleFor, test } from 'ember-qunit'; import { moduleFor, test } from 'ember-qunit';
moduleFor('controller:application', 'Unit | Controller | application', { moduleFor('controller:application', 'Unit | Controller | application', {
// Specify the other units that are required for this test. needs: ['service:storage']
// needs: ['controller:foo']
}); });
// Replace this with your real tests.
test('it exists', function(assert) { test('it exists', function(assert) {
let controller = this.subject(); let controller = this.subject();
assert.ok(controller); assert.ok(controller);

View File

@ -1,8 +1,7 @@
import { moduleFor, test } from 'ember-qunit'; import { moduleFor, test } from 'ember-qunit';
moduleFor('controller:index', 'Unit | Controller | index', { moduleFor('controller:index', 'Unit | Controller | index', {
// Specify the other units that are required for this test. needs: ['service:storage']
// needs: ['controller:foo']
}); });
// Replace this with your real tests. // Replace this with your real tests.

View File

@ -1,8 +1,7 @@
import { moduleFor, test } from 'ember-qunit'; import { moduleFor, test } from 'ember-qunit';
moduleFor('route:index', 'Unit | Route | index', { moduleFor('route:index', 'Unit | Route | index', {
// Specify the other units that are required for this test. needs: ['service:storage']
// needs: ['controller:foo']
}); });
test('it exists', function(assert) { test('it exists', function(assert) {