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

feat: run initial test using jest findRelatedTests #3234

Merged
merged 1 commit into from
Nov 9, 2021

Conversation

Djaler
Copy link
Contributor

@Djaler Djaler commented Oct 28, 2021

Resolves #1655

@Djaler
Copy link
Contributor Author

Djaler commented Oct 28, 2021

@nicojs there are one failed e2e case jest-mutate-outside-roots. Looks like findRelatedTests doesn't find test when source file is outside roots. How we should handle this case?

@nicojs
Copy link
Member

nicojs commented Oct 28, 2021

Hi Djaler, you can see the workaround we used for mutantRun:

 ​    ​if​ ​(fileNameUnderTest​ ​&&​ ​this.jestConfig.roots)​ ​{ 
 ​      ​// Make sure the file under test lives inside one of the roots

(Line 156)

That should work.

PR looks good as far as I can see on my phone 📱. Will take a closer look when build is green.

@Djaler
Copy link
Contributor Author

Djaler commented Oct 30, 2021

@nicojs done

@nicojs
Copy link
Member

nicojs commented Oct 30, 2021

Thx, I'll take a look next Monday

@nicojs nicojs merged commit b2e4584 into stryker-mutator:master Nov 9, 2021
@nicojs
Copy link
Member

nicojs commented Nov 9, 2021

Took me a full week longer, but here it is 😅

This will be released with the next minor release, hopefully in a few days.

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.

Run only related tests on initial run
2 participants