Page MenuHomeSoftware Heritage

tests: extract most of test_*_origin_visit tests in a helper function
ClosedPublic

Authored by douardda on Aug 28 2019, 2:09 PM.

Diff Detail

Repository
rDJNL Journal infrastructure
Branch
current
Lint
Lint Skipped
Unit
Unit Tests Skipped
Build Status
Buildable 7518
Build 10752: tox-on-jenkinsJenkins
Build 10751: arc lint + arc unit

Event Timeline

vlorentz added a subscriber: vlorentz.
vlorentz added inline comments.
swh/journal/tests/test_replay.py
111

The docstring should explain what it does

146–148

rename visits to expected_visits and visitsout to visits or actual_visits, for consistency with other tests.

147

assert len(visitsout) == len(visits), visitsout

156

redundant

This revision now requires changes to proceed.Aug 28 2019, 4:49 PM
swh/journal/tests/test_replay.py
156

nope, vin vs vout

rebased + changes according to volrentz' comments

swh/journal/tests/test_replay.py
156

Indeed. But why did you remove it, then?

swh/journal/tests/test_replay.py
156

humm not sure any more. let me dig this a bit further

swh/journal/tests/test_replay.py
156

oh yes I do remember, because I do not want to handle/check all the different possible ways this 'origin' has been send into kafka (str vs. int vs dict).

I believe...

This revision is now accepted and ready to land.Aug 29 2019, 3:35 PM

fix a typo in test_replay.py

This revision was automatically updated to reflect the committed changes.