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
89a21640
Verified
Commit
89a21640
authored
Nov 02, 2021
by
Baptiste Beauplat
Browse files
Add unit test to check for dsc url and name without any repository files installed
parent
6b0194bf
Changes
1
Hide whitespace changes
Inline
Side-by-side
tests/unit/packages/test_packages.py
View file @
89a21640
...
...
@@ -28,7 +28,7 @@
from
tests
import
TestController
from
debexpo.packages.models
import
Package
,
Priority
,
Project
,
Distribution
,
\
Section
,
Component
,
BinaryPackage
Section
,
Component
,
BinaryPackage
,
PackageUpload
class
TestPackagesController
(
TestController
):
...
...
@@ -62,3 +62,10 @@ class TestPackagesController(TestController):
binary
.
delete
()
self
.
assertEquals
(
''
,
package
.
get_description
())
def
test_get_dsc_no_files
(
self
):
package
=
Package
.
objects
.
get
(
name
=
'testpackage'
)
upload
=
PackageUpload
.
objects
.
get
(
package
=
package
)
self
.
assertEquals
(
None
,
upload
.
get_dsc_url
())
self
.
assertEquals
(
None
,
upload
.
get_dsc_name
())
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