6005-backupLabeler #2276

Merged
pablone merged 50 commits from 6005-backupLabeler into dev 2024-04-12 07:12:54 +00:00
1 changed files with 0 additions and 40 deletions
Showing only changes of commit a35a790155 - Show all commits

View File

@ -1,40 +0,0 @@
const models = require('vn-loopback/server/server').models;
const https = require('https');
xdescribe('boxing getVideo()', () => {
it('should return data', async() => {
const tx = await models.PackingSiteConfig.beginTransaction({});
try {
const options = {transaction: tx};
const id = 1;
const video = 'video.mp4';
const response = {
pipe: () => {},
on: () => {},
end: () => {},
};
const req = {
headers: 'apiHeader',
data: {
pipe: () => {},
on: () => {},
}
};
spyOn(https, 'request').and.returnValue(response);
const result = await models.Boxing.getVideo(id, video, req, null, options);
expect(result[0]).toEqual(response.data.videos[0].filename);
await tx.rollback();
} catch (e) {
await tx.rollback();
throw e;
}
});
});