-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Closed
Labels
Internal ToolingIssues related to our tooling and monorepo infrastructoreIssues related to our tooling and monorepo infrastructorespike
Description
Let's try to speed up our dev process and CI builds by migrating to ts-jest.
- Jest can run tests in parallel and provides clever watch mode.
- ts-jest compiles TypeScript files on the fly, removing the need for costly build.
- Jest provides tools for snapshot-based testing, this would be very useful to test CLI code scaffolding TypeScript files and to test code emitting OpenAPI spec.
Known problems to resolve:
-
@loopback/metadatarelies oninstanceof Functioncheck that does not work under Jest, see fix(metadata): don't rely oninstanceofchecks #3160 -
@loopback/bootis not able to find & load artifacts from original.tsfiles - Tests using classes defined outside of the scope of test functions fail with ReferenceError, e.g.
ReferenceError: Cannot access 'CustomerController' before initialization. - Integration with express is broken
- Repository bindings are not picked up (
The key 'repositories.NoteRepository' is not bound to any value in context application)
See the list of skipped files in https://github.com/strongloop/loopback-next/blob/test/jest/jest.config.js for the up-to-date information.
Metadata
Metadata
Assignees
Labels
Internal ToolingIssues related to our tooling and monorepo infrastructoreIssues related to our tooling and monorepo infrastructorespike