Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
.then(() => {
expect(errs.length).toBe(1);
expect(myApp.wasBootstrapped()).toEqual(true);
expect(myApp.wasMounted()).toEqual(false);
expect(singleSpa.getMountedApps()).toEqual([]);
expect(singleSpa.getAppStatus('./bootstrap-rejects.app.js')).toEqual(singleSpa.SKIP_BECAUSE_BROKEN);
})
});
.then(() => {
expect(errs.length).toBeGreaterThan(0);
expect(errs[0].appName).toBe('invalid-load-2');
expect(errs[0].message.indexOf('single-spa loading function did not return a promise. Check the second argument to registerApplication')).toBeGreaterThan(-1)
expect(singleSpa.getAppStatus('invalid-load-2')).toBe(singleSpa.SKIP_BECAUSE_BROKEN);
})
});
.then(() => {
expect(errs.length).toBeGreaterThan(0);
expect(errs[0].appName).toBe('invalid-load-1');
expect(errs[0].message.indexOf('single-spa loading function did not return a promise. Check the second argument to registerApplication')).toBeGreaterThan(-1)
expect(singleSpa.getAppStatus('invalid-load-1')).toBe(singleSpa.SKIP_BECAUSE_BROKEN);
})
});