]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/tests/plugins/plugin-helpers.ts
server/mw/oauth: res.loc.auth to true upon auth
[github/Chocobozzz/PeerTube.git] / server / tests / plugins / plugin-helpers.ts
index e76d7917a1a8826766a2bc10b45a8c20eaa745c3..c0d95e1e0cad3f251d8dae877e8376e79cfce66a 100644 (file)
@@ -16,6 +16,7 @@ import {
 } from '../../../shared/extra-utils'
 import { cleanupTests, flushAndRunMultipleServers, ServerInfo, waitUntilLog } from '../../../shared/extra-utils/server/servers'
 import { expect } from 'chai'
+import { HttpStatusCode } from '../../../shared/core-utils/miscs/http-error-codes'
 
 function postCommand (server: ServerInfo, command: string, bodyArg?: object) {
   const body = { command }
@@ -25,7 +26,7 @@ function postCommand (server: ServerInfo, command: string, bodyArg?: object) {
     url: server.url,
     path: '/plugins/test-four/router/commander',
     fields: body,
-    statusCodeExpected: 204
+    statusCodeExpected: HttpStatusCode.NO_CONTENT_204
   })
 }