test(docs-infra): increase timeout for all redirection tests (#28103)

Occasionally, URLs take longer to load, which causes CI flakes.
In #27903, the timeout for external URLs was increased, but internal
URLs turned out to be affected as well.

PR Close #28103
This commit is contained in:
George Kalpakas 2019-01-12 18:26:18 +02:00 committed by Andrew Kushnir
parent 6fff74e576
commit 48a03fcc80
1 changed files with 2 additions and 4 deletions

View File

@ -27,16 +27,14 @@ describe(browser.baseUrl, () => {
describe('(with legacy URLs)', () => {
page.legacyUrls.forEach(([fromUrl, toUrl], i) => {
const isExternalUrl = /^https?:/.test(toUrl);
it(`should redirect '${fromUrl}' to '${toUrl}' (${i + 1}/${page.legacyUrls.length})`, async () => {
await page.goTo(fromUrl);
const expectedUrl = stripTrailingSlash(isExternalUrl ? toUrl : page.baseUrl + toUrl);
const expectedUrl = stripTrailingSlash(/^https?:/.test(toUrl) ? toUrl : page.baseUrl + toUrl);
const actualUrl = await getCurrentUrl();
expect(actualUrl).toBe(expectedUrl);
}, isExternalUrl ? 60000 : undefined);
}, 60000);
});
});