mirror of
https://github.com/Kong/insomnia
synced 2024-11-08 23:00:30 +00:00
5f4c19da35
Co-authored-by: Opender Singh <opender.singh@konghq.com>
24 lines
859 B
TypeScript
24 lines
859 B
TypeScript
import * as globalPackage from '../../package.json';
|
|
import { globalBeforeEach } from '../__jest__/before-each';
|
|
|
|
describe('package.json', () => {
|
|
beforeEach(globalBeforeEach);
|
|
|
|
it('all packed dependencies should exist', () => {
|
|
for (const name of globalPackage.packedDependencies) {
|
|
const version = globalPackage.dependencies[name];
|
|
expect(version).toBeDefined();
|
|
}
|
|
});
|
|
|
|
it('packages must be included in webpack build or else errors happen', () => {
|
|
// If this is built by Webpack it fails on multipart/form-data
|
|
expect(globalPackage.packedDependencies.includes('httpsnippet')).toBe(false);
|
|
});
|
|
|
|
it('packages must NOT be included in webpack build or else errors happen', () => {
|
|
// PDFJS breaks if not part of Webpack build
|
|
expect(globalPackage.packedDependencies.includes('pdfjs-dist')).toBe(true);
|
|
});
|
|
});
|