Added runners stats tests
continuous-integration/drone/pr Build is failing
Details
continuous-integration/drone/pr Build is failing
Details
ref #190
This commit is contained in:
parent
63964fbf2c
commit
7111068361
|
@ -42,4 +42,22 @@ describe('GET /api/stats should return 200', () => {
|
|||
expect(res.status).toEqual(200);
|
||||
expect(res.headers['content-type']).toContain("application/json");
|
||||
});
|
||||
});
|
||||
// ---------------
|
||||
describe('GET /api/stats/runners/* should return 200', () => {
|
||||
it('get by distance w/ auth should return 200', async () => {
|
||||
const res = await axios.get(base + '/api/stats/runners/distance', axios_config_stats);
|
||||
expect(res.status).toEqual(200);
|
||||
expect(res.headers['content-type']).toContain("application/json");
|
||||
});
|
||||
it('get by donations w/ auth should return 200', async () => {
|
||||
const res = await axios.get(base + '/api/stats/runners/donations', axios_config_stats);
|
||||
expect(res.status).toEqual(200);
|
||||
expect(res.headers['content-type']).toContain("application/json");
|
||||
});
|
||||
it('get by laptime w/ auth should return 200', async () => {
|
||||
const res = await axios.get(base + '/api/stats/runners/laptime', axios_config_stats);
|
||||
expect(res.status).toEqual(200);
|
||||
expect(res.headers['content-type']).toContain("application/json");
|
||||
});
|
||||
});
|
Loading…
Reference in New Issue