Page MenuHomeSoftware Heritage

pytest.ini: Avoid loading django plugin to prevent fixture name clash
AbandonedPublic

Authored by anlambert on Apr 23 2020, 2:59 PM.

Details

Reviewers
None
Group Reviewers
Reviewers
Summary

pytest-django and pytest-flask both declare a fixture named client and
the wrong one may be picked when running swh-scanner tests.

So avoid the loading of pytest django plugin to prevent errors when
running tests.

Diff Detail

Repository
rDTSCN Code scanner
Branch
master
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 12008
Build 18211: Phabricator diff pipeline on jenkinsJenkins console · Jenkins
Build 18210: arc lint + arc unit

Event Timeline

Build has FAILED

Patch application report for D3052 (id=10853)

Rebasing onto 3bca054d47...

Current branch diff-target is up to date.
Changes applied before test
commit bdbc369bbf30a934a09683244233f7b85157f8fc
Author: Antoine Lambert <antoine.lambert@inria.fr>
Date:   Thu Apr 23 14:58:18 2020 +0200

    pytest.ini: Avoid loading django plugin to prevent fixture name clash
    
    pytest-django and pytest-flask both declare a fixture named client and
    the wrong one may be picked when running swh-scanner tests.
    
    So avoid the loading of pytest django plugin to prevent errors when
    running tests.

Link to build: https://jenkins.softwareheritage.org/job/DTSCN/job/tests-on-diff/9/
See console output for more information: https://jenkins.softwareheritage.org/job/DTSCN/job/tests-on-diff/9/console

It was already there, lol

Looks like addopts already has the proper flag two lines below!