test: Rename internal method to something public

It's used in multiple module tests now.
This commit is contained in:
Antoine R. Dumont (@ardumont) 2021-01-25 13:35:07 +01:00
parent d3fe3d5747
commit 7f1609265f
No known key found for this signature in database
GPG key ID: 52E2E9840D10C3B8
2 changed files with 6 additions and 6 deletions

View file

@ -14,7 +14,7 @@ from requests.status_codes import codes
from swh.lister import USER_AGENT
from swh.lister.gitlab.lister import GitLabLister, _parse_page_id
from swh.lister.pattern import ListerStats
from swh.lister.tests.test_utils import _assert_sleep_calls
from swh.lister.tests.test_utils import assert_sleep_calls
from swh.lister.utils import WAIT_EXP_BASE
logger = logging.getLogger(__name__)
@ -204,7 +204,7 @@ def test_lister_gitlab_rate_limit(swh_scheduler, requests_mock, datadir, mocker)
expected_nb_origins = len(response1) + len(response2)
assert listed_result == ListerStats(pages=2, origins=expected_nb_origins)
_assert_sleep_calls(mocker, mock_sleep, [1, WAIT_EXP_BASE])
assert_sleep_calls(mocker, mock_sleep, [1, WAIT_EXP_BASE])
@pytest.mark.parametrize(