From 1b5b10d13152d704d2396a1e53d56aba1a8e7e03 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Thu, 30 Nov 2017 13:15:25 +0100 Subject: Fix activitypub check headers --- server/tests/utils/activitypub.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 server/tests/utils/activitypub.ts (limited to 'server/tests/utils') diff --git a/server/tests/utils/activitypub.ts b/server/tests/utils/activitypub.ts new file mode 100644 index 000000000..cf3c1c3b3 --- /dev/null +++ b/server/tests/utils/activitypub.ts @@ -0,0 +1,15 @@ +import * as request from 'supertest' + +function makeActivityPubGetRequest (url: string, path: string) { + return request(url) + .get(path) + .set('Accept', 'application/activity+json,text/html;q=0.9,\\*/\\*;q=0.8') + .expect(200) + .expect('Content-Type', /json/) +} + +// --------------------------------------------------------------------------- + +export { + makeActivityPubGetRequest +} -- cgit v1.2.3