Make websocket-test the first test, and give custom timeouts of 1000ms

This commit is contained in:
Nicholas Dudfield
2014-01-05 13:40:47 +07:00
parent ff12d9adaa
commit da3881a486
2 changed files with 7 additions and 1 deletions

View File

@@ -3,6 +3,6 @@
--ui tdd
--timeout 10000
--slow 600
test/server-test.js
test/websocket-test.js
test/server-test.js
test/*-test.{js,coffee}

View File

@@ -9,6 +9,8 @@ suite('WebSocket connection', function() {
var server;
setup(function(done) {
this.timeout(1000);
var cfg = extend({}, config.default_server_config, config.servers.alpha);
if (cfg.no_server) {
done();
@@ -20,6 +22,8 @@ suite('WebSocket connection', function() {
});
teardown(function(done) {
this.timeout(1000);
if (config.servers.alpha.no_server) {
done();
} else {
@@ -29,6 +33,8 @@ suite('WebSocket connection', function() {
});
test('WebSocket connect and disconnect', function(done) {
this.timeout(1000);
var alpha = Remote.from_config("alpha");
alpha.on('connected', function () {