From: Chocobozzz Date: Thu, 29 Mar 2018 09:22:27 +0000 (+0200) Subject: Add reverse proxy test in travis X-Git-Tag: v1.0.0-beta.3~3 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=09becad8e85cc4007ff862b26fa4195f3d0e7c8d;p=oweals%2Fpeertube.git Add reverse proxy test in travis --- diff --git a/client/src/app/core/auth/auth.service.ts b/client/src/app/core/auth/auth.service.ts index d31c61496..69ae3e5e1 100644 --- a/client/src/app/core/auth/auth.service.ts +++ b/client/src/app/core/auth/auth.service.ts @@ -70,7 +70,8 @@ export class AuthService { if (error.status === 403) { errorMessage = `Cannot retrieve OAuth Client credentials: ${error.text}. \n` - errorMessage += 'Ensure you have correctly configured PeerTube (config/ directory), in particular the "webserver" section.' + errorMessage += 'Ensure you have correctly configured PeerTube (config/ directory), ' + + 'in particular the "webserver" section.' } // We put a bigger timeout diff --git a/server/initializers/constants.ts b/server/initializers/constants.ts index 986fed099..5152095b3 100644 --- a/server/initializers/constants.ts +++ b/server/initializers/constants.ts @@ -238,7 +238,7 @@ const CONSTRAINTS_FIELDS = { const RATES_LIMIT = { LOGIN: { WINDOW_MS: 5 * 60 * 1000, // 5 minutes - MAX: 10 // 10 attempts + MAX: 15 // 15 attempts } } diff --git a/server/tests/api/index-fast.ts b/server/tests/api/index-fast.ts index 464dcb5e0..aa063b97a 100644 --- a/server/tests/api/index-fast.ts +++ b/server/tests/api/index-fast.ts @@ -11,3 +11,4 @@ import './videos/video-privacy' import './videos/services' import './server/email' import './server/config' +import './server/reverse-proxy' diff --git a/server/tests/api/server/reverse-proxy.ts b/server/tests/api/server/reverse-proxy.ts index aa4b3ae81..4c2655f64 100644 --- a/server/tests/api/server/reverse-proxy.ts +++ b/server/tests/api/server/reverse-proxy.ts @@ -64,7 +64,7 @@ describe('Test application behind a reverse proxy', function () { it('Should rate limit logins', async function () { const user = { username: 'root', password: 'fail' } - for (let i = 0; i < 9; i++) { + for (let i = 0; i < 14; i++) { await userLogin(server, user, 400) }