Skip to content

Update nx config for tests#2685

Merged
smallsaucepan merged 5 commits intomasterfrom
mf/nx-cleanup
May 17, 2025
Merged

Update nx config for tests#2685
smallsaucepan merged 5 commits intomasterfrom
mf/nx-cleanup

Conversation

@mfedderly
Copy link
Collaborator

@mfedderly mfedderly commented Aug 7, 2024

This fixes an issue where nx would cache test runs even if the underlying files have changed. This only happens if you execute tests like so:

pnpm lerna run test --scope=@turf/meta

This invokes the lerna/nx caching layer, and this will miss the fact that the actual code itself changed which should cause the tests to rerun. To fix this I extracted the source file inputs into a named input, and then used that in both build and test so that everything stays in sync.

Tests only require that the dependencies have been built, not the package itself
@mfedderly
Copy link
Collaborator Author

This might not be worth merging if we're taking #2682 instead, or it would at least need to be revisited.

@mfedderly
Copy link
Collaborator Author

I reworked this to just not conflict with that PR, we can merge this safely now.

@smallsaucepan
Copy link
Member

Thanks for this @mfedderly 👍

@smallsaucepan smallsaucepan merged commit 60c861b into master May 17, 2025
3 checks passed
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.

3 participants