diff options
Diffstat (limited to 'server/tests/utils')
-rw-r--r-- | server/tests/utils/requests/requests.ts | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/server/tests/utils/requests/requests.ts b/server/tests/utils/requests/requests.ts index ebde692cd..b88b3ce5b 100644 --- a/server/tests/utils/requests/requests.ts +++ b/server/tests/utils/requests/requests.ts | |||
@@ -123,6 +123,13 @@ function makePutBodyRequest (options: { | |||
123 | .expect(options.statusCodeExpected) | 123 | .expect(options.statusCodeExpected) |
124 | } | 124 | } |
125 | 125 | ||
126 | function makeHTMLRequest (url: string, path: string) { | ||
127 | return request(url) | ||
128 | .get(path) | ||
129 | .set('Accept', 'text/html') | ||
130 | .expect(200) | ||
131 | } | ||
132 | |||
126 | function updateAvatarRequest (options: { | 133 | function updateAvatarRequest (options: { |
127 | url: string, | 134 | url: string, |
128 | path: string, | 135 | path: string, |
@@ -149,6 +156,7 @@ function updateAvatarRequest (options: { | |||
149 | // --------------------------------------------------------------------------- | 156 | // --------------------------------------------------------------------------- |
150 | 157 | ||
151 | export { | 158 | export { |
159 | makeHTMLRequest, | ||
152 | makeGetRequest, | 160 | makeGetRequest, |
153 | makeUploadRequest, | 161 | makeUploadRequest, |
154 | makePostBodyRequest, | 162 | makePostBodyRequest, |