Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

chore(deps): update dependency requests to v2.31.0 [security]#2627

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
nejch merged 2 commits intomainfromjlvillal/requests
Aug 19, 2023
Merged
Show file tree
Hide file tree
Changes fromall commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletionrequirements-test.txt
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -6,6 +6,6 @@ pytest-cov==4.1.0
pytest-github-actions-annotate-failures==0.2.0
pytest==7.4.0
PyYaml==6.0.1
responses==0.23.1
responses==0.23.3
setuptools==68.0.0
wheel==0.41.0
2 changes: 1 addition & 1 deletionrequirements.txt
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
requests==2.28.2
requests==2.31.0
requests-toolbelt==1.0.0
typing-extensions==4.7.1 ; python_version < "3.8"
5 changes: 0 additions & 5 deletionstests/unit/objects/conftest.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -21,11 +21,6 @@ def created_content():
return {"message":"201 Created"}


@pytest.fixture
defno_content():
return {"message":"204 No Content"}


@pytest.fixture
defresp_export(accepted_content,binary_content):
"""Common fixture for group and project exports."""
Expand Down
4 changes: 1 addition & 3 deletionstests/unit/objects/test_badges.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -97,13 +97,11 @@ def resp_update_badge():


@pytest.fixture()
defresp_delete_badge(no_content):
defresp_delete_badge():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url=re.compile(r"http://localhost/api/v4/(projects|groups)/1/badges/1"),
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
2 changes: 0 additions & 2 deletionstests/unit/objects/test_group_access_tokens.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -75,8 +75,6 @@ def resp_revoke_group_access_token():
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/groups/1/access_tokens/42",
json=content,
content_type="application/json",
status=204,
)
rsps.add(
Expand Down
10 changes: 3 additions & 7 deletionstests/unit/objects/test_groups.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -215,7 +215,7 @@ def resp_update_push_rules_group():


@pytest.fixture
defresp_delete_push_rules_group(no_content):
defresp_delete_push_rules_group():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.GET,
Expand All@@ -227,15 +227,13 @@ def resp_delete_push_rules_group(no_content):
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/groups/1/push_rule",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps


@pytest.fixture
defresp_list_ldap_group_links(no_content):
defresp_list_ldap_group_links():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.GET,
Expand DownExpand Up@@ -292,7 +290,7 @@ def resp_create_saml_group_link():


@pytest.fixture
defresp_delete_saml_group_link(no_content):
defresp_delete_saml_group_link():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.POST,
Expand All@@ -309,8 +307,6 @@ def resp_delete_saml_group_link(no_content):
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/groups/1/saml_group_links/saml-group-1",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
4 changes: 1 addition & 3 deletionstests/unit/objects/test_job_artifacts.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -25,13 +25,11 @@ def resp_artifacts_by_ref_name(binary_content):


@pytest.fixture
defresp_project_artifacts_delete(no_content):
defresp_project_artifacts_delete():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/projects/1/artifacts",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
6 changes: 2 additions & 4 deletionstests/unit/objects/test_members.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -23,7 +23,7 @@


@pytest.fixture
defresp_create_group_member(no_content):
defresp_create_group_member():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.POST,
Expand All@@ -49,13 +49,11 @@ def resp_list_billable_group_members():


@pytest.fixture
defresp_delete_billable_group_member(no_content):
defresp_delete_billable_group_member():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/groups/1/billable_members/1",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
12 changes: 3 additions & 9 deletionstests/unit/objects/test_packages.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -137,33 +137,29 @@ def resp_get_package():


@pytest.fixture
defresp_delete_package(no_content):
defresp_delete_package():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/projects/1/packages/1",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps


@pytest.fixture
defresp_delete_package_file(no_content):
defresp_delete_package_file():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/projects/1/packages/1/package_files/1",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps


@pytest.fixture
defresp_delete_package_file_list(no_content):
defresp_delete_package_file_list():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.GET,
Expand All@@ -178,8 +174,6 @@ def resp_delete_package_file_list(no_content):
rsps.add(
method=responses.DELETE,
url=f"http://localhost/api/v4/projects/1/packages/1/package_files/{pkg_file_id}",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
4 changes: 1 addition & 3 deletionstests/unit/objects/test_personal_access_tokens.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -81,13 +81,11 @@ def resp_get_personal_access_token_self():


@pytest.fixture
defresp_delete_personal_access_token(no_content):
defresp_delete_personal_access_token():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url=single_token_url,
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
2 changes: 0 additions & 2 deletionstests/unit/objects/test_project_access_tokens.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -75,8 +75,6 @@ def resp_revoke_project_access_token():
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/projects/1/access_tokens/42",
json=content,
content_type="application/json",
status=204,
)
rsps.add(
Expand Down
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -147,13 +147,11 @@ def resp_mr_approval_rules():


@pytest.fixture
defresp_delete_mr_approval_rule(no_content):
defresp_delete_mr_approval_rule():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/projects/1/merge_requests/1/approval_rules/1",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
12 changes: 3 additions & 9 deletionstests/unit/objects/test_projects.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -361,13 +361,11 @@ def resp_share_project():


@pytest.fixture
defresp_unshare_project(no_content):
defresp_unshare_project():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/projects/1/share/1",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand All@@ -387,13 +385,11 @@ def resp_create_fork_relation():


@pytest.fixture
defresp_delete_fork_relation(no_content):
defresp_delete_fork_relation():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/projects/2/fork",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand DownExpand Up@@ -485,7 +481,7 @@ def resp_update_push_rules_project():


@pytest.fixture
defresp_delete_push_rules_project(no_content):
defresp_delete_push_rules_project():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.GET,
Expand All@@ -497,8 +493,6 @@ def resp_delete_push_rules_project(no_content):
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/projects/1/push_rule",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
4 changes: 1 addition & 3 deletionstests/unit/objects/test_registry_repositories.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -59,13 +59,11 @@ def resp_get_registry_repository():


@pytest.fixture
defresp_delete_registry_repository(no_content):
defresp_delete_registry_repository():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/projects/1/registry/repositories/1",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
4 changes: 1 addition & 3 deletionstests/unit/objects/test_releases.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -101,13 +101,11 @@ def resp_update_link():


@pytest.fixture
defresp_delete_link(no_content):
defresp_delete_link():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url=link_id_url,
json=link_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
4 changes: 1 addition & 3 deletionstests/unit/objects/test_secure_files.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -65,13 +65,11 @@ def resp_download_secure_file(binary_content):


@pytest.fixture
defresp_remove_secure_file(no_content):
defresp_remove_secure_file():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/projects/1/secure_files/1",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
2 changes: 0 additions & 2 deletionstests/unit/objects/test_todos.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -66,8 +66,6 @@ def resp_mark_all_as_done():
rsps.add(
method=responses.POST,
url="http://localhost/api/v4/todos/mark_as_done",
json={},
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
4 changes: 1 addition & 3 deletionstests/unit/objects/test_topics.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -78,13 +78,11 @@ def resp_update_topic():


@pytest.fixture
defresp_delete_topic(no_content):
defresp_delete_topic():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url=topic_url,
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
4 changes: 1 addition & 3 deletionstests/unit/objects/test_users.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -152,13 +152,11 @@ def resp_get_user_status():


@pytest.fixture
defresp_delete_user_identity(no_content):
defresp_delete_user_identity():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url="http://localhost/api/v4/users/1/identities/test_provider",
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down
4 changes: 1 addition & 3 deletionstests/unit/objects/test_variables.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -87,13 +87,11 @@ def resp_update_variable():


@pytest.fixture
defresp_delete_variable(no_content):
defresp_delete_variable():
withresponses.RequestsMock()asrsps:
rsps.add(
method=responses.DELETE,
url=variables_key_url,
json=no_content,
content_type="application/json",
status=204,
)
yieldrsps
Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp