Page MenuHomeSoftware Heritage

pytest_plugin: Make the datadir() fixture session-scoped
AbandonedPublicDraft

Authored by vlorentz on Nov 28 2022, 5:09 PM.

Details

Reviewers
None
Group Reviewers
Reviewers
Summary

It allows using it in fixtures which aren't function-scoped

Diff Detail

Unit TestsFailed

TimeTest
0 msJenkins > .tox.py3-core-db-server-github-slow-cover.lib.python3.7.site-packages.swh.core.db.tests.test_cli::test_cli_swh_db_create_and_init_db
request = <SubRequest 'datadir' for <Function test_get_response_cb_with_encoded_url>> @pytest.fixture(scope="session")
0 msJenkins > .tox.py3-core-db-server-github-slow-cover.lib.python3.7.site-packages.swh.core.db.tests.test_cli::test_cli_swh_db_create_and_init_db_new_api
request = <SubRequest 'datadir' for <Function test_get_response_cb_with_encoded_url>> @pytest.fixture(scope="session")
1 msJenkins > .tox.py3-core-db-server-github-slow-cover.lib.python3.7.site-packages.swh.core.db.tests.test_cli::test_cli_swh_db_initialization_fail_without_creation_first
request = <SubRequest 'datadir' for <Function test_get_response_cb_with_encoded_url>> @pytest.fixture(scope="session")
0 msJenkins > .tox.py3-core-db-server-github-slow-cover.lib.python3.7.site-packages.swh.core.db.tests.test_cli::test_cli_swh_db_initialization_fail_without_extension
request = <SubRequest 'datadir' for <Function test_get_response_cb_with_encoded_url>> @pytest.fixture(scope="session")
0 msJenkins > .tox.py3-core-db-server-github-slow-cover.lib.python3.7.site-packages.swh.core.db.tests.test_cli::test_cli_swh_db_initialization_idempotent
request = <SubRequest 'datadir' for <Function test_get_response_cb_with_encoded_url>> @pytest.fixture(scope="session")
View Full Test Results (38 Failed · 279 Passed · 1 Skipped)

Event Timeline

Build has FAILED

Patch application report for D8893 (id=32048)

Rebasing onto 306a74d01a...

Current branch diff-target is up to date.
Changes applied before test
commit 311892e30a5834c688e13fed32a96ccf52292505
Author: Valentin Lorentz <vlorentz@softwareheritage.org>
Date:   Mon Nov 28 17:09:47 2022 +0100

    pytest_plugin: Make the datadir() fixture session-scoped
    
    It allows using it in fixtures which aren't function-scoped

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

Harbormaster returned this revision to the author for changes because remote builds failed.Nov 28 2022, 5:11 PM
Harbormaster failed remote builds in B32997: Diff 32048!