mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
fix(test): FastAPI 0.87.0 - warning fixes
FastAPI 0.87.0 switched to the httpx library for their TestClient * cookies need to be defined on the request instance instead of method calls Signed-off-by: moson-mo <mo-son@mailbox.org>
This commit is contained in:
parent
1216399d53
commit
a832b3cddb
10 changed files with 463 additions and 281 deletions
|
@ -197,7 +197,8 @@ def test_metadata_change(
|
|||
with client as request:
|
||||
endp = f"/pkgbase/{pkgbasename}/keywords"
|
||||
post_data = {"keywords": "abc def"}
|
||||
resp = request.post(endp, data=post_data, cookies=cookies, allow_redirects=True)
|
||||
request.cookies = cookies
|
||||
resp = request.post(endp, data=post_data)
|
||||
assert resp.status_code == HTTPStatus.OK
|
||||
|
||||
# Run main() again, which should now produce a new commit with the
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue