mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
change(routers.packages): delete_package -> pkgbase_delete_instance
`delete_package` was processing package deletions through `Package` instances. This doesn't make sense; if we delete a package, we want to target its package base. This new function vastly simplifies the previous. Signed-off-by: Kevin Morris <kevr@0cost.org>
This commit is contained in:
parent
53fabdfaea
commit
c735f9868b
2 changed files with 23 additions and 50 deletions
|
@ -2483,9 +2483,9 @@ def test_packages_post_delete(caplog: pytest.fixture, client: TestClient,
|
|||
assert successes[0].text.strip() == expected
|
||||
|
||||
# Expect that the package deletion was logged.
|
||||
packages = [package.Name]
|
||||
pkgbases = [package.PackageBase.Name]
|
||||
expected = (f"Privileged user '{tu_user.Username}' deleted the "
|
||||
f"following packages: {str(packages)}.")
|
||||
f"following package bases: {str(pkgbases)}.")
|
||||
assert expected in caplog.text
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue