Page MenuHomeSoftware Heritage

Make the project usable in the webapp tests
ClosedPublic

Authored by vsellier on Apr 14 2021, 10:18 AM.

Details

Summary

Add an in memory implementatiom that will be used in the webapp's tests

Related to T3231

Diff Detail

Repository
rDCNT Archive counters
Branch
master
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 20708
Build 32139: Phabricator diff pipeline on jenkinsJenkins console · Jenkins
Build 32138: arc lint + arc unit

Event Timeline

Build is green

Patch application report for D5518 (id=19679)

Rebasing onto 15f72b75df...

First, rewinding head to replay your work on top of it...
Applying: Make the project usable in the webapp tests
Changes applied before test
commit 04d720acbebcc0316fe408d0a36a21e4de113511
Author: Vincent SELLIER <vincent.sellier@softwareheritage.org>
Date:   Wed Apr 14 10:06:22 2021 +0200

    Make the project usable in the webapp tests
    
    Add an in memory implementatiom that will be used in the webapp's tests
    
    Related to T3231

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

ardumont added a subscriber: ardumont.

lgtm

Remarks inline.

swh/counters/in_memory.py
23

for imperative instruction (understand 'procedure' a-la c of sort), use a standard for loop

swh/counters/tests/test_inmemory.py
54

couldn't you reuse the tests from the other implementation?

This revision is now accepted and ready to land.Apr 14 2021, 10:44 AM
swh/counters/in_memory.py
14
20–21

with defaultdict(int) suggestion, this ^ can go away.

swh/counters/in_memory.py
14

my bad, defaultdict(set)

take review's feedbacks in consideration

Build is green

Patch application report for D5518 (id=19681)

Rebasing onto 15f72b75df...

First, rewinding head to replay your work on top of it...
Applying: Make the project usable in the webapp tests
Changes applied before test
commit 07f0ed943ed4584577f9008fa43e6dc2485d21da
Author: Vincent SELLIER <vincent.sellier@softwareheritage.org>
Date:   Wed Apr 14 10:06:22 2021 +0200

    Make the project usable in the webapp tests
    
    Add an in memory implementatiom that will be used in the webapp's tests
    
    Related to T3231

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

This revision was landed with ongoing or failed builds.Apr 14 2021, 11:18 AM
This revision was automatically updated to reflect the committed changes.

Build is green

Patch application report for D5518 (id=19682)

Rebasing onto 15f72b75df...

Current branch diff-target is up to date.
Changes applied before test
commit 0e5d551ff59ba8d1ced24cfb93a5e3d5ba36a293
Author: Vincent SELLIER <vincent.sellier@softwareheritage.org>
Date:   Wed Apr 14 10:06:22 2021 +0200

    Make the project usable in the webapp tests
    
    Add an in memory implementatiom that will be used in the webapp's tests
    
    Related to T3231

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