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

testscript: relax constraints around actual source in cmp with update #107

Merged
merged 1 commit into from
Jul 31, 2020

Conversation

myitcv
Copy link
Collaborator

@myitcv myitcv commented Jul 30, 2020

There are currently constraints on the actual source for a failed cmp
comparison when Params.UpdateScripts is true: the actual must be either
stdout or stderr.

However it's unclear why this constraint is necessary.

Indeed it's a painful constraint when the actual source in a comparison
is file written by a previous command.

Relax this constraint because, after discussion with @mvdan
and @rogpeppe, we believe it safe to do so.

Add a test for this new logic where the actual is a file that is part of
the archive.

@myitcv myitcv requested a review from rogpeppe July 30, 2020 13:13
@rogpeppe
Copy link
Owner

LGTM with one trivial typo. Thanks!

@myitcv myitcv force-pushed the testscript_relax_cmp_constraints branch from b31249b to 4d976e3 Compare July 31, 2020 10:47
There are currently constraints on the actual source for a failed cmp
comparison when Params.UpdateScripts is true: the actual must be either
stdout or stderr.

However it's unclear why this constraint is necessary.

Indeed it's a painful constraint when the actual source in a comparison
is file written by a previous command.

Relax this constraint because, after discussion with @mvdan and
@rogpeppe, we believe it is safe to do so.

Add a test for this new logic where the actual is a file that is part of
the archive.
@myitcv myitcv force-pushed the testscript_relax_cmp_constraints branch from 4d976e3 to 28c666f Compare July 31, 2020 15:14
@myitcv myitcv merged commit 76dc4b3 into master Jul 31, 2020
@myitcv myitcv deleted the testscript_relax_cmp_constraints branch July 31, 2020 15:24
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