Compare commits

...

2 Commits

Author SHA1 Message Date
dcdbdd15ac Ptotential fix for stats failing
Some checks failed
continuous-integration/drone/pr Build is failing
ref #190
2021-04-07 16:28:48 +02:00
132b48cf2a Removed console log for passing tests
ref #190
2021-04-07 16:26:12 +02:00
2 changed files with 3 additions and 2 deletions

View File

@ -51,6 +51,9 @@ export abstract class RunnerGroup {
*/
@IsInt()
public get distance(): number {
if (!this.runners || this.runners.length == 0) {
return 0;
}
return this.runners.reduce((sum, current) => sum + current.distance, 0);
}

View File

@ -72,8 +72,6 @@ describe('GET /api/stats/teams/* should return 200', () => {
});
it('get by donations w/ auth should return 200', async () => {
const res = await axios.get(base + '/api/stats/teams/donations', axios_config_stats);
console.log("################# Teams by donations #################");
console.log(res.data);
expect(res.status).toEqual(200);
expect(res.headers['content-type']).toContain("application/json");
});