activitypub.ts 491 B

123456789101112131415
  1. import * as request from 'supertest'
  2. import { HttpStatusCode } from '../../../shared/core-utils/miscs/http-error-codes'
  3. function makeActivityPubGetRequest (url: string, path: string, expectedStatus = HttpStatusCode.OK_200) {
  4. return request(url)
  5. .get(path)
  6. .set('Accept', 'application/activity+json,text/html;q=0.9,\\*/\\*;q=0.8')
  7. .expect(expectedStatus)
  8. }
  9. // ---------------------------------------------------------------------------
  10. export {
  11. makeActivityPubGetRequest
  12. }