Added test for single card generation with returnCards=true

ref #180
This commit is contained in:
Nicolai Ort 2021-03-28 18:46:25 +02:00
parent 5a36c8dcae
commit 6005b0661f
1 changed files with 6 additions and 0 deletions

View File

@ -156,6 +156,12 @@ describe('POST /api/cards/bulk successfully', () => {
expect(res.status).toEqual(200);
expect(res.headers['content-type']).toContain("application/json");
});
it('creating a single new bulk card and letting the system return it should return 200', async () => {
const res = await axios.post(base + '/api/cards/bulk?count=1&returnCards=true', {}, axios_config);
expect(res.status).toEqual(200);
expect(res.headers['content-type']).toContain("application/json");
expect(res.data[0].id).toBeDefined();
});
it('creating 50 new bulk card should return 200', async () => {
const res = await axios.post(base + '/api/cards/bulk?count=50', {}, axios_config);
expect(res.status).toEqual(200);