From a39605f9d7a0832a89fb823e8231a34cdc07e921 Mon Sep 17 00:00:00 2001 From: Clement Michaud Date: Fri, 8 Sep 2017 23:18:20 +0200 Subject: [PATCH] Stabilize integration tests by increasing timeouts --- test/features/step_definitions/hooks.ts | 4 ++++ test/features/step_definitions/redirection.ts | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/test/features/step_definitions/hooks.ts b/test/features/step_definitions/hooks.ts index 708bd3ae..7f844ad3 100644 --- a/test/features/step_definitions/hooks.ts +++ b/test/features/step_definitions/hooks.ts @@ -3,6 +3,10 @@ import fs = require("fs"); import BluebirdPromise = require("bluebird"); import ChildProcess = require("child_process"); +Cucumber.defineSupportCode(function({ setDefaultTimeout }) { + setDefaultTimeout(20 * 1000); +}); + Cucumber.defineSupportCode(function({ After, Before }) { const exec = BluebirdPromise.promisify(ChildProcess.exec); diff --git a/test/features/step_definitions/redirection.ts b/test/features/step_definitions/redirection.ts index 240fa318..8b29ee72 100644 --- a/test/features/step_definitions/redirection.ts +++ b/test/features/step_definitions/redirection.ts @@ -12,6 +12,6 @@ Cucumber.defineSupportCode(function ({ Given, When, Then }) { }); Then("I'm redirected to {stringInDoubleQuotes}", function (link: string) { - return this.driver.wait(seleniumWebdriver.until.urlContains(link), 5000); + return this.driver.wait(seleniumWebdriver.until.urlContains(link), 15000); }); }); \ No newline at end of file