You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As a developer I want to have a good signal to noise ration and want to write my tests with as less boilerplate as possible.
Paths are environment specific and cause boilerplate to get properly tested.
Therefor I need a custom matcher for paths.
// windows 'C:\Documnets\my-projects\project-root'// linux '/home/my-projects/project-root'expect(process.cwd()).toContainPath('project-root/other-folder');expect(process.cwd()).toEndsWithPath('project-root/other-folder/src');
Acceptance criteria
I want to be able to use the custom matcher in the following libs:
vitest
Internal logic:
it handles path differences of all OS
I want to be able to have different matcher present:
toContainPath('...')
toEndWithPath('...')
the existing code is using the helper, e.g. nx-plugin tests for persist.outputDir
Activity
hanna-skryl commentedon Jan 23, 2025
@BioPhoton Hasn't #876 resolved this issue?
BioPhoton commentedon Feb 11, 2025
I am not able to use them ATM :D type issues
BioPhoton commentedon Jan 5, 2026
Working now.