-
Notifications
You must be signed in to change notification settings - Fork 274
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
test(git): advanced test cases for include/exclude filters #5472
test(git): advanced test cases for include/exclude filters #5472
Conversation
86724cf
to
a2a6237
Compare
6cf5c57
to
03b8d33
Compare
e144b09
to
19f2003
Compare
d99ef0d
to
8d6b780
Compare
To make sure include filter behaves equally when exclude is empty and undefined
When the filename matches the filter, but the file path does not.
This does not make much sense. Hashes must be verified in the disk-based test projects. This makes the results fo the failed tests more readable.
To test the function against both `VcsHandler` implementations: - `GitHandler` - `GitRepoHandler`
Make sure the same scan mode is used in all git handlers created while testing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me so far! 👍 as far as I understand the portions of the code that need to change in PRs that land soon are marked using the // FIXME
comments, right?
{ | ||
name: "when directory is included by name with globs", | ||
// FIXME: shouldn't just '**/deepdir' work well too? | ||
pathBuilder: (_subDirName: string, deepDirName) => join("**", deepDirName, "**", "*"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be good to use both path.posix.join
and path.win32.join
in the future for tests, to make sure that we are compatible with both backslashes and forward slashes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, I can add it in the next PR.
@stefreak, no, those might be related to a separate bug. In the next PR I'll add test cases and fix for #5317. Let's see if that change fix also fixes the FIXME comments. |
b4aacd4
to
b1462fa
Compare
What this PR does / why we need it:
In this PR:
Which issue(s) this PR fixes:
Special notes for your reviewer: