Files
xod/packages/xod-deploy/test-func/uploader.spec.js
Evgeny Kochetkov e6ab08e297 chore(infra): format code with prettier
Just `yarn lint  --fix`
2018-03-05 17:59:03 +03:00

21 lines
552 B
JavaScript

import { assert } from 'chai';
import { getUploadConfig } from '../src/uploader';
describe('Uploader', () => {
it('should get board upload config from endpoint', async () => {
const res = await getUploadConfig('uno');
assert.hasAllKeys(res, [
'tool',
'cmdTemplate',
'disableFlushing',
'touch1200bps',
'waitForPort',
]);
});
it('should get 404 error for non existent boardId', () =>
getUploadConfig('super_mega_non_existent_boardId').catch(err => {
assert.equal(err.status, 404);
}));
});