aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/tests/plugins/external-auth.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-07-13 09:43:59 +0200
committerChocobozzz <me@florianbigard.com>2021-07-20 15:27:18 +0200
commit6c5065a011b099618681a37bd77eaa7bd3db752e (patch)
tree352252a00b25013c4b1902f6bcd9668aba295c7b /server/tests/plugins/external-auth.ts
parent0d8ecb7592577f54012413a2b5a9b159cfc90399 (diff)
downloadPeerTube-6c5065a011b099618681a37bd77eaa7bd3db752e.tar.gz
PeerTube-6c5065a011b099618681a37bd77eaa7bd3db752e.tar.zst
PeerTube-6c5065a011b099618681a37bd77eaa7bd3db752e.zip
Introduce server commands
Diffstat (limited to 'server/tests/plugins/external-auth.ts')
-rw-r--r--server/tests/plugins/external-auth.ts7
1 files changed, 3 insertions, 4 deletions
diff --git a/server/tests/plugins/external-auth.ts b/server/tests/plugins/external-auth.ts
index 09a107ca2..f7cee588a 100644
--- a/server/tests/plugins/external-auth.ts
+++ b/server/tests/plugins/external-auth.ts
@@ -17,8 +17,7 @@ import {
17 setAccessTokensToServers, 17 setAccessTokensToServers,
18 updateMyUser, 18 updateMyUser,
19 userLogin, 19 userLogin,
20 wait, 20 wait
21 waitUntilLog
22} from '@shared/extra-utils' 21} from '@shared/extra-utils'
23import { User, UserRole } from '@shared/models' 22import { User, UserRole } from '@shared/models'
24 23
@@ -127,7 +126,7 @@ describe('Test external auth plugins', function () {
127 126
128 await loginUsingExternalToken(server, 'cyan', externalAuthToken, HttpStatusCode.BAD_REQUEST_400) 127 await loginUsingExternalToken(server, 'cyan', externalAuthToken, HttpStatusCode.BAD_REQUEST_400)
129 128
130 await waitUntilLog(server, 'expired external auth token', 2) 129 await server.serversCommand.waitUntilLog('expired external auth token', 2)
131 }) 130 })
132 131
133 it('Should auto login Cyan, create the user and use the token', async function () { 132 it('Should auto login Cyan, create the user and use the token', async function () {
@@ -217,7 +216,7 @@ describe('Test external auth plugins', function () {
217 }) 216 })
218 217
219 it('Should have logged out Cyan', async function () { 218 it('Should have logged out Cyan', async function () {
220 await waitUntilLog(server, 'On logout cyan') 219 await server.serversCommand.waitUntilLog('On logout cyan')
221 220
222 await getMyUserInformation(server.url, cyanAccessToken, HttpStatusCode.UNAUTHORIZED_401) 221 await getMyUserInformation(server.url, cyanAccessToken, HttpStatusCode.UNAUTHORIZED_401)
223 }) 222 })