Removing unnecessary timeout in integration tests

This commit is contained in:
Jeffrey Morgan 2015-06-18 18:00:29 -07:00
Родитель b65d8e1552
Коммит d45b249f74
1 изменённых файлов: 7 добавлений и 9 удалений

Просмотреть файл

@ -9,16 +9,14 @@ describe('HubUtil Integration Tests', () => {
describe('auth', () => { describe('auth', () => {
pit('successfully authenticates', () => { pit('successfully authenticates', () => {
return new Promise((resolve) => { return new Promise((resolve) => {
setTimeout(() => { hubUtil.auth(process.env.INTEGRATION_USER, process.env.INTEGRATION_PASSWORD, (error, response, body) => {
hubUtil.auth(process.env.INTEGRATION_USER, process.env.INTEGRATION_PASSWORD, (error, response, body) => { expect(response.statusCode).toBe(200);
expect(response.statusCode).toBe(200); expect(error).toBe(null);
expect(error).toBe(null);
let data = JSON.parse(body); let data = JSON.parse(body);
expect(data.token).toBeTruthy(); expect(data.token).toBeTruthy();
resolve(); resolve();
}); });
}, 5000);
}); });
}); });