-
Notifications
You must be signed in to change notification settings - Fork 9
tests: use correct HEAD
to list files
#51
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
Conversation
When checking the files before the patch, after a checkout to 'HEAD~', it is required to use the previous HEAD, not the new one to look at the same files and not others. While at it, always use the $HEAD variable, and also fix a related comment + added an extra one to explain the diff. Signed-off-by: Matthieu Baerts (NGI0) <[email protected]>
I forgot to add: I didn't check, and I only noticed this while quickly looking at the new scripts. So hopefully I'm fixing the right thing correctly :) |
Not related to the modifications here, but about the new tests. For Shellcheck, when I started to enforce it in MPTCP, I ended up disabling SC2086 (Double quote to prevent globbing and word splitting) for most files (see I guess we don't want massive clean-ups simply adding double quotes where it was safe without them. Maybe we could keep this rule for new files (and if it was compliant before), but it adds some complexity in the scripts here. Or adding Maybe shellcheck could be used with |
Thanks for the fix!! |
I was wondering about that one. It's really annoying but it has found bugs in my code in the past :S In any case, I trust your judgement on this, I'm not a bash expert. If you think it's going to be too noisy to be practical we can disable it in the shellcheck script. Maybe @pabeni has a preference ?
Or we can adjust the regexp for counting? Again, I lack the bash experience - but for Oh, and as you probably noticed we count errors and warnings+checks separately. The checks and warnings are pretty much "for maintainer review", not a hard failure. We exit with 250 if we found only warnings and checks and NIPA reports that to patchwork as warning rather than fail. |
Yes, me too, that's why I keep it usually for new scripts.
Good idea, so we can still see the ignored ones in the logs. I can look at that during my lunch break.
I quickly checked:
The two big ones are "info" type ones:
It makes sense. Hopefully it will be easy to spot the warning/error ones :) |
When checking the files before the patch, after a checkout to
HEAD~
, it is required to use the previousHEAD
, not the new one to look at the same files and not others.While at it, always use the
$HEAD
variable, and also fix a related comment + added an extra one to explain the diff.