From 096641566f2663076c3b0d5a1947ecb7efb29fc0 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 8 Sep 2017 17:10:57 +0200 Subject: Convert real world script to typescript --- server/tests/utils/request-schedulers.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'server/tests/utils') diff --git a/server/tests/utils/request-schedulers.ts b/server/tests/utils/request-schedulers.ts index ae8227b79..f100f6d99 100644 --- a/server/tests/utils/request-schedulers.ts +++ b/server/tests/utils/request-schedulers.ts @@ -1,12 +1,14 @@ import * as request from 'supertest' -function getRequestsStats (server: { url: string }, accessToken: string) { - const path = '/api/v1/requests/stats' +import { ServerInfo } from '../utils' + +function getRequestsStats (server: ServerInfo) { + const path = '/api/v1/request-schedulers/stats' return request(server.url) .get(path) .set('Accept', 'application/json') - .set('Authorization', 'Bearer ' + accessToken) + .set('Authorization', 'Bearer ' + server.accessToken) .expect(200) .expect('Content-Type', /json/) } -- cgit v1.2.3