Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Jest projects #1294

Merged
merged 9 commits into from
Oct 11, 2023
Merged

Use Jest projects #1294

merged 9 commits into from
Oct 11, 2023

Conversation

samchungy
Copy link
Contributor

@samchungy samchungy commented Oct 11, 2023

Utilise and spruik Jest projects because it's pretty

image

Unfortunately running integration tests only in band via projects is not supported 😢

jestjs/jest#10936

@changeset-bot
Copy link

changeset-bot bot commented Oct 11, 2023

🦋 Changeset detected

Latest commit: 413d844

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
skuba Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

jest.config.ts Outdated
Comment on lines 18 to 25
projects: [
{
transform,
moduleNameMapper,
setupFiles,
displayName: 'unit',
testPathIgnorePatterns: ['<rootDir>/template/', '\\.int\\.test\\.ts'],
},
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be too heavy handed for Jest.mergePreset to provide the root defaults to each project, like e.g.

projects: projects.map(project => ({ transform, moduleNameMapper, ...project })

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah I wasn't sure, I think it makes sense though

@samchungy samchungy marked this pull request as ready for review October 11, 2023 08:23
@samchungy samchungy requested review from a team as code owners October 11, 2023 08:23
Copy link
Member

@72636c 72636c left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🙇

src/api/jest/index.ts Outdated Show resolved Hide resolved
Comment on lines +8 to +11
watchPathIgnorePatterns: [
'<rootDir>/integration/format/',
'<rootDir>/integration/lint/',
],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🙇

Co-authored-by: Ryan Ling <ryan@outlook.com.au>
@samchungy samchungy merged commit 2d8b57a into master Oct 11, 2023
@samchungy samchungy deleted the use-jest-projects branch October 11, 2023 23:19
@seek-oss-ci seek-oss-ci mentioned this pull request Oct 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants