2023-01-24 08:04:43 +00:00
|
|
|
const {models} = require('vn-loopback/server/server');
|
2020-03-26 18:10:09 +00:00
|
|
|
|
2022-05-12 09:43:41 +00:00
|
|
|
describe('newCollection()', () => {
|
|
|
|
it('should return a new collection', async() => {
|
|
|
|
pending('#3400 analizar que hacer con rutas de back collection');
|
2021-06-23 11:24:23 +00:00
|
|
|
let ctx = {req: {accessToken: {userId: 1106}}};
|
2023-01-24 08:04:43 +00:00
|
|
|
let response = await models.Collection.newCollection(ctx, 1, 1, 1);
|
2020-03-26 18:10:09 +00:00
|
|
|
|
|
|
|
expect(response.length).toBeGreaterThan(0);
|
2021-09-01 09:48:21 +00:00
|
|
|
expect(response[0].ticketFk).toEqual(2);
|
2020-03-26 18:10:09 +00:00
|
|
|
});
|
|
|
|
});
|