Page MenuHomeSoftware Heritage

test: Fix parse_swhid failing test
ClosedPublic

Authored by ardumont on Jan 15 2021, 1:42 PM.

Details

Reviewers
zack
Group Reviewers
Reviewers
Commits
rDDEP22c4e585ecc4: test: Fix failing test
Summary

This no longer checks the error message.

Fixes build [1]

[1] https://jenkins.softwareheritage.org/job/DDEP/job/tests/1273/console

Test Plan

tox

Diff Detail

Repository
rDDEP Push deposit
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

Build is green

Patch application report for D4870 (id=17261)

Rebasing onto 2c47667ab6...

Current branch diff-target is up to date.
Changes applied before test
commit 19e5a6dc21e89e39bc00b35fc74568414e9a8339
Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org>
Date:   Fri Jan 15 13:41:16 2021 +0100

    test: Fix parse_swhid error message change failing test
    
    Fixes build [1]
    
    [1] https://jenkins.softwareheritage.org/job/DDEP/job/tests/1273/console

See https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/528/ for more details.

zack requested changes to this revision.Jan 15 2021, 2:03 PM
zack added a subscriber: zack.

Why do we still have tests that check error messages meant for human consumption, again? :-)
If the difference in how they fail is meaningful (which I don't know), they should raise different exceptions and we should just check their types.

The right fix here is stop checking those and just check that the raise failures or something.
Otherwise we will be here again, in the future, doing busy work maintaining tests that fail for entirely pointless reasons.

This revision now requires changes to proceed.Jan 15 2021, 2:03 PM

Why do we still have tests that check error messages meant for human consumption, again? :-)

Probably because those were anterior to our discussion on this.
And right now, i was more concentrated on fixing the build and go run my
sprint than fixing properly this.

Ack, i'll try to simplify the checks.

ardumont retitled this revision from test: Fix parse_swhid error message change failing test to test: Fix parse_swhid failing test.Jan 15 2021, 2:46 PM
ardumont edited the summary of this revision. (Show Details)

Build is green

Patch application report for D4870 (id=17274)

Rebasing onto 2c47667ab6...

Current branch diff-target is up to date.
Changes applied before test
commit 22c4e585ecc475e063283b848157ec2a625819bc
Author: Antoine R. Dumont (@ardumont) <ardumont@softwareheritage.org>
Date:   Fri Jan 15 13:41:16 2021 +0100

    test: Fix failing test
    
    This no longer checks the error messages.
    
    Fixes build [1]
    
    [1] https://jenkins.softwareheritage.org/job/DDEP/job/tests/1273/console

See https://jenkins.softwareheritage.org/job/DDEP/job/tests-on-diff/529/ for more details.

This revision is now accepted and ready to land.Jan 15 2021, 3:49 PM
This revision was automatically updated to reflect the committed changes.