System tests for mirror show & update with filters. #64

This commit is contained in:
Andrey Smirnov
2014-07-16 13:56:26 +04:00
parent 69ad2ccd84
commit cf4619784e
4 changed files with 67 additions and 0 deletions
+22
View File
@@ -0,0 +1,22 @@
Name: mirror4
Archive Root URL: http://security.debian.org/
Distribution: wheezy/updates
Components: main
Architectures: amd64, armel, armhf, i386, ia64, kfreebsd-amd64, kfreebsd-i386, mips, mipsel, powerpc, s390, s390x, sparc
Download Sources: no
Filter: nginx | Priority (required)
Filter With Deps: yes
Last update: never
Information from release file:
Architectures: amd64 armel armhf i386 ia64 kfreebsd-amd64 kfreebsd-i386 mips mipsel powerpc s390 s390x sparc
Codename: wheezy
Components: updates/main updates/contrib updates/non-free
Date: Sun, 13 Jul 2014 12:12:08 UTC
Description: Debian 7.0 Security Updates
Label: Debian-Security
Origin: Debian
Suite: stable
Valid-Until: Wed, 23 Jul 2014 12:12:08 UTC
Version: 7.0
+19
View File
@@ -0,0 +1,19 @@
Applying filter...
Building download queue...
Download queue: 2 items (17.38 KiB)
Downloading & parsing package files...
Downloading http://download.opensuse.org/repositories/home:/DeepDiver1975/xUbuntu_10.04/InRelease...
Downloading http://download.opensuse.org/repositories/home:/DeepDiver1975/xUbuntu_10.04/Packages.bz2...
Downloading http://download.opensuse.org/repositories/home:/DeepDiver1975/xUbuntu_10.04/Packages.gz...
Downloading http://download.opensuse.org/repositories/home:/DeepDiver1975/xUbuntu_10.04/Release...
Downloading http://download.opensuse.org/repositories/home:/DeepDiver1975/xUbuntu_10.04/Release.gpg...
Downloading http://download.opensuse.org/repositories/home:/DeepDiver1975/xUbuntu_10.04/Sources.bz2...
Downloading http://download.opensuse.org/repositories/home:/DeepDiver1975/xUbuntu_10.04/Sources.gz...
Downloading http://download.opensuse.org/repositories/home:/DeepDiver1975/xUbuntu_10.04/amd64/libiniparser_3.1-1_amd64.deb...
Downloading http://download.opensuse.org/repositories/home:/DeepDiver1975/xUbuntu_10.04/i386/libiniparser_3.1-1_i386.deb...
Mirror `flat-src` has been successfully updated.
Packages filtered: 5 -> 2.
gpgv: Good signature from "home:DeepDiver1975 OBS Project <home:DeepDiver1975@build.opensuse.org>"
gpgv: Signature made Tue May 21 23:01:30 2013 MSK using DSA key ID 1048C1FF
+11
View File
@@ -25,3 +25,14 @@ class ShowMirror3Test(BaseTest):
fixtureDB = True
runCmd = "aptly mirror show --with-packages wheezy-contrib"
outputMatchPrepare = lambda _, s: re.sub(r"Last update: [0-9:+A-Za-z -]+\n", "", s)
class ShowMirror4Test(BaseTest):
"""
show mirror: mirror with filter
"""
fixtureCmds = [
"aptly mirror create -ignore-signatures -filter='nginx | Priority (required)' -filter-with-deps=true mirror4 http://security.debian.org/ wheezy/updates main"
]
runCmd = "aptly mirror show mirror4"
outputMatchPrepare = lambda _, s: re.sub(r"(Date|Valid-Until): [,0-9:+A-Za-z -]+\n", "", s)
+15
View File
@@ -125,3 +125,18 @@ class UpdateMirror9Test(BaseTest):
def output_processor(self, output):
return "\n".join(sorted(output.split("\n")))
class UpdateMirror10Test(BaseTest):
"""
update mirrors: filtered
"""
fixtureGpg = True
fixtureCmds = [
"aptly mirror create -keyring=aptlytest.gpg -with-sources -filter='!(Name (% *-dev)), !($$PackageType (source))' flat-src http://download.opensuse.org/repositories/home:/DeepDiver1975/xUbuntu_10.04/ ./",
]
runCmd = "aptly mirror update --keyring=aptlytest.gpg flat-src"
outputMatchPrepare = lambda _, s: re.sub(r'Signature made .* using', '', s)
def output_processor(self, output):
return "\n".join(sorted(output.split("\n")))