Skip to content
Myr

test: Update request.test.ts to remove duplicate checks (#2984)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Joaquim Ley · committed by GitHub · parent 57c95d4 · Browse files · 1 file+0 added−6 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+0 added−6 removed

  • tests:+0 added−6 removed

1 file+0 added−6 removed

modified:src/request.test.ts-6 removed
174 unmodified lines
175 body: text,176 })177 )178 expect(await req.text()).toEqual(text)179 expect(await req.text()).toEqual(text)179 expect(await req.json()).toEqual(json)180 expect(await req.arrayBuffer()).toEqual(buffer)181 expect(await req.blob()).toEqual(182 new Blob([text], {
9 unmodified lines
192 body: '{"foo":"bar"}',193 })194 )195 expect(await req.json()).toEqual(json)197 expect(await req.json()).toEqual(json)196 expect(await req.text()).toEqual(text)197 expect(await req.arrayBuffer()).toEqual(buffer)198 expect(await req.blob()).toEqual(199 new Blob([text], {
10 unmodified lines
210 body: buffer,211 })212 )213 expect(await req.arrayBuffer()).toEqual(buffer)216 expect(await req.arrayBuffer()).toEqual(buffer)214 expect(await req.text()).toEqual(text)215 expect(await req.json()).toEqual(json)216 expect(await req.blob()).toEqual(217 new Blob([text], {
12 unmodified lines
230 body: blob,231 })232 )233 expect(await req.blob()).toEqual(blob)237 expect(await req.blob()).toEqual(blob)234 expect(await req.text()).toEqual(text)235 expect(await req.json()).toEqual(json)236 expect(await req.arrayBuffer()).toEqual(buffer)237 })
7 unmodified lines
245 body: data,246 })247 )248 expect((await req.formData()).get('foo')).toBe('bar')253 expect((await req.formData()).get('foo')).toBe('bar')249 expect(async () => await req.text()).not.toThrow()250 expect(async () => await req.arrayBuffer()).not.toThrow()251 expect(async () => await req.blob()).not.toThrow()252 })
8 unmodified lines
261 body: data,262 })263 )264 expect((await req.parseBody())['foo']).toBe('bar')270 expect((await req.parseBody())['foo']).toBe('bar')265 expect(async () => await req.text()).not.toThrow()266 expect(async () => await req.arrayBuffer()).not.toThrow()267 expect(async () => await req.blob()).not.toThrow()268 })
47 unmodified lines