const app = require('vn-loopback/server/server'); describe('device checkUuid()', () => { it('should return an state equal to false', async() => { let ctx = {req: {accessToken: {userId: 9}}}; let data = {'uuid': '123', 'model': 'ihpne kike molon'}; let result = await app.models.Device.checkUuid(ctx, data); expect(result.name).toBeFalsy(); }); });