mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-05-06 22:18:28 +00:00
Tests for mirroring repositories with signatures.
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
import re
|
||||
|
||||
from lib import BaseTest
|
||||
|
||||
|
||||
@@ -82,3 +84,51 @@ class CreateMirror8Test(BaseTest):
|
||||
]
|
||||
runCmd = "aptly mirror create --ignore-signatures mirror8 http://mirror.yandex.ru/debian/ wheezy main contrib"
|
||||
expectedCode = 1
|
||||
|
||||
|
||||
class CreateMirror9Test(BaseTest):
|
||||
"""
|
||||
create mirror: repo with InRelease verification
|
||||
"""
|
||||
runCmd = "aptly mirror create --keyring=aptlytest.gpg mirror9 http://mirror.yandex.ru/debian-backports/ squeeze-backports"
|
||||
fixtureGpg = True
|
||||
outputMatchPrepare = lambda _, s: re.sub(r'Signature made .* using', '', s)
|
||||
|
||||
def check(self):
|
||||
self.check_output()
|
||||
self.check_cmd_output("aptly mirror show mirror9", "mirror_show")
|
||||
|
||||
|
||||
class CreateMirror10Test(BaseTest):
|
||||
"""
|
||||
create mirror: repo with InRelease verification, failure
|
||||
"""
|
||||
runCmd = "aptly mirror create --keyring=aptlytest.gpg mirror10 http://mirror.yandex.ru/debian-backports/ squeeze-backports"
|
||||
fixtureGpg = False
|
||||
gold_processor = BaseTest.expand_environ
|
||||
outputMatchPrepare = lambda _, s: re.sub(r'Signature made .* using', '', s)
|
||||
expectedCode = 1
|
||||
|
||||
|
||||
class CreateMirror11Test(BaseTest):
|
||||
"""
|
||||
create mirror: repo with Release + Release.gpg verification
|
||||
"""
|
||||
runCmd = "aptly mirror create --keyring=aptlytest.gpg mirror11 http://mirror.yandex.ru/debian/ squeeze"
|
||||
fixtureGpg = True
|
||||
outputMatchPrepare = lambda _, s: re.sub(r'Signature made .* using', '', s)
|
||||
|
||||
def check(self):
|
||||
self.check_output()
|
||||
self.check_cmd_output("aptly mirror show mirror11", "mirror_show")
|
||||
|
||||
|
||||
class CreateMirror12Test(BaseTest):
|
||||
"""
|
||||
create mirror: repo with Release+Release.gpg verification, failure
|
||||
"""
|
||||
runCmd = "aptly mirror create --keyring=aptlytest.gpg mirror12 http://mirror.yandex.ru/debian/ squeeze"
|
||||
fixtureGpg = False
|
||||
gold_processor = BaseTest.expand_environ
|
||||
outputMatchPrepare = lambda _, s: re.sub(r'Signature made .* using', '', s)
|
||||
expectedCode = 1
|
||||
|
||||
Reference in New Issue
Block a user