Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
mentors.debian.net
debexpo
Commits
b1f7d427
Verified
Commit
b1f7d427
authored
Nov 04, 2021
by
Baptiste Beauplat
Browse files
Update test to cover the no gitstorage case on upload removal
parent
89a21640
Changes
1
Hide whitespace changes
Inline
Side-by-side
tests/functional/packages/test_removeolduploads.py
View file @
b1f7d427
...
...
@@ -30,6 +30,9 @@ import logging
from
email
import
message_from_string
from
http.server
import
BaseHTTPRequestHandler
from
django.conf
import
settings
from
django.test
import
override_settings
# from debexpo.lib.email import Email
from
debexpo.accounts.models
import
User
from
debexpo.packages.models
import
Package
,
PackageUpload
,
Distribution
,
\
...
...
@@ -194,7 +197,10 @@ class TestCronjobRemoveOldUploads(TestController):
remove_old_uploads
()
self
.
_assert_cronjob_success
()
def
test_remove_uploads_expired
(
self
):
@
override_settings
()
def
test_remove_uploads_expired_no_gistorage
(
self
):
del
settings
.
GIT_STORAGE
self
.
_setup_packages
(
include_expired
=
True
)
remove_old_uploads
()
self
.
_assert_cronjob_success
()
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment