System tests for mirror/repo/snapshot rename commands. #63

This commit is contained in:
Andrey Smirnov
2014-07-26 17:28:16 +04:00
parent c5922737ed
commit b9c8a8d9da
18 changed files with 141 additions and 0 deletions
+35
View File
@@ -0,0 +1,35 @@
from lib import BaseTest
class RenameRepo1Test(BaseTest):
"""
rename repo: regular operations
"""
fixtureCmds = [
"aptly repo create repo1",
]
runCmd = "aptly repo rename repo1 repo2"
def check(self):
self.check_output()
self.check_cmd_output("aptly repo list", "repo_list")
class RenameRepo2Test(BaseTest):
"""
rename repo: missing repo
"""
runCmd = "aptly repo rename repo2 repo3"
expectedCode = 1
class RenameRepo3Test(BaseTest):
"""
rename repo: already exists
"""
fixtureCmds = [
"aptly repo create repo3",
"aptly repo create repo4",
]
runCmd = "aptly repo rename repo3 repo4"
expectedCode = 1