A jest plugin to ensure assertions happen within all tests at runtime
Published by ballercat about 3 years ago
This version includes a breaking API change
New feature, add getStackTrace
to onInvokeTask
. This allows users to inspect the stack prior to blocking a task.
taskType
and taskSource
have been replaced with a task
object in the onInvokeTask
API
Published by ballercat about 3 years ago
Version 2.1.0 breaks public API this is a correction to version 2.x
Published by ballercat about 3 years ago
New feature, add getStackTrace
to onInvokeTask
. This allows users to inspect the stack prior to blocking a task.
Published by ballercat over 4 years ago
This release comes with a major patch that may fail a larger portion of your tests.
test('unhandled promise rejections fail tests', () => {
Promise.resolve().then(() => {
throw new Error('oops');
});
return wait(() => {
expect(1).toBe(1);
});
});
With plugin versions prior to v2.0.0
the test above would pass. This brings the plugin inline with Jest behavior, which will fail the test above by default.
API Changes
ignoreStack[]
option can be used to control which parts of the stack(s) are printed by the plugin when alerting on ignored async tasks. This was previously undocumented.Published by ballercat almost 5 years ago
Patch to existing bootstrap to add support for JSDOM environments. Fixes issues with setTimeout family of functions not properly zoned.
New public apis:
jest-plugin-must-assert/jsdom
instead of just the default jest-plugin-must-assert
jest-plugin-must-assert/jsdom-munual
instead of just the default manual setup jest-plugin-must-assert/manual
Published by ballercat almost 5 years ago
Published by ballercat over 5 years ago