Skip to content

Commit 11e2ef7

Browse files
committed
Cleans up tests for jshint/travis/et al
1 parent 3d6dc7f commit 11e2ef7

File tree

3 files changed

+18
-15
lines changed

3 files changed

+18
-15
lines changed

tests/.jshintrc

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,13 @@
2121
"andThen",
2222
"currentURL",
2323
"currentPath",
24-
"currentRouteName"
24+
"currentRouteName",
25+
"require",
26+
"describe",
27+
"before",
28+
"beforeEach",
29+
"it",
30+
"process"
2531
],
2632
"node": false,
2733
"browser": false,

tests/runner.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/*jshint globalstrict: true*/
12
'use strict';
23

34
var glob = require('glob');

tests/unit/index-nodetest.js

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
1+
/*jshint globalstrict: true*/
12
'use strict';
23

3-
var Promise = require('ember-cli/lib/ext/promise');
44
var assert = require('ember-cli/tests/helpers/assert');
5-
var fs = require('fs');
6-
var path = require('path');
75

86
describe('ssh-tunnel plugin', function() {
97
var subject, mockUi;
@@ -77,7 +75,7 @@ describe('ssh-tunnel plugin', function() {
7775
config: config
7876
};
7977
plugin.beforeHook(context);
80-
assert.throws(function(error){
78+
assert.throws(function(){
8179
plugin.configure(context);
8280
});
8381
var messages = mockUi.messages.reduce(function(previous, current) {
@@ -117,7 +115,7 @@ describe('ssh-tunnel plugin', function() {
117115
host: 'example.com',
118116
username: 'ghedamat'
119117
}
120-
}
118+
};
121119
context = {
122120
ui: mockUi,
123121
config: config
@@ -147,11 +145,11 @@ describe('ssh-tunnel plugin', function() {
147145
username: 'example',
148146
password: 'secret'
149147
}
150-
}
148+
};
151149
context = {
152150
ui: mockUi,
153151
config: config
154-
}
152+
};
155153
plugin.beforeHook(context);
156154
plugin.configure(context);
157155
assert.isDefined(config['ssh-tunnel'].password);
@@ -165,11 +163,11 @@ describe('ssh-tunnel plugin', function() {
165163
username: 'example',
166164
privateKeyPath: '~/.ssh/id_rsa'
167165
}
168-
}
166+
};
169167
context = {
170168
ui: mockUi,
171169
config: config
172-
}
170+
};
173171
plugin.beforeHook(context);
174172
plugin.configure(context);
175173
assert.isUndefined(config['ssh-tunnel'].password);
@@ -180,8 +178,7 @@ describe('ssh-tunnel plugin', function() {
180178
});
181179

182180
describe('setup hook', function() {
183-
var plugin;
184-
var context;
181+
var plugin, context;
185182

186183
beforeEach(function() {
187184
plugin = subject.createDeployPlugin({
@@ -222,8 +219,7 @@ describe('ssh-tunnel plugin', function() {
222219
});
223220

224221
describe('teardown hook', function() {
225-
var plugin;
226-
var context;
222+
var plugin, context;
227223

228224
beforeEach(function() {
229225
plugin = subject.createDeployPlugin({
@@ -250,7 +246,7 @@ describe('ssh-tunnel plugin', function() {
250246
}
251247
};
252248

253-
var result = plugin.teardown(context);
249+
plugin.teardown(context);
254250
});
255251
});
256252
});

0 commit comments

Comments
 (0)