]>
Commit | Line | Data |
---|---|---|
8d309058 C |
1 | 'use strict' |
2 | ||
3 | const request = require('supertest') | |
4 | ||
5 | const clientsUtils = { | |
6 | getClient: getClient | |
7 | } | |
8 | ||
9 | // ---------------------- Export functions -------------------- | |
10 | ||
11 | function getClient (url, end) { | |
3fad43ac | 12 | const path = '/api/v1/clients/local' |
8d309058 C |
13 | |
14 | request(url) | |
15 | .get(path) | |
16 | .set('Accept', 'application/json') | |
17 | .expect(200) | |
18 | .expect('Content-Type', /json/) | |
19 | .end(end) | |
20 | } | |
21 | ||
22 | // --------------------------------------------------------------------------- | |
23 | ||
24 | module.exports = clientsUtils |