aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2019-10-27 11:16:26 +0100
committerGuido Günther <agx@sigxcpu.org>2019-10-27 18:07:56 +0100
commit7e351b96068e3851f63fe3d7298e956c955eed66 (patch)
tree0ac1b125022e1920d6116a2ce580b37bff0bde0c
parent4a97a1ccc8364b6cd0f5f119ea7bce2979f237d9 (diff)
test_import_dsc.py: Test signature import
-rw-r--r--tests/component/deb/test_import_dsc.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/component/deb/test_import_dsc.py b/tests/component/deb/test_import_dsc.py
index a3b0aea..3cdd283 100644
--- a/tests/component/deb/test_import_dsc.py
+++ b/tests/component/deb/test_import_dsc.py
@@ -367,3 +367,20 @@ class TestImportDsc(ComponentTestBase):
ok_(os.path.exists("./configure.ac"))
ok_(not os.path.exists("./debian/patches/series"))
ok_(not os.path.exists("./debian/patches/AUTHORS"))
+
+ def test_import_signature(self):
+ dscfile = self._dsc30('2.8-1')
+ assert import_dsc(['arg0',
+ '--verbose',
+ '--pristine-tar',
+ '--debian-branch=master',
+ '--upstream-branch=upstream',
+ dscfile]) == 0
+ repo = ComponentTestGitRepository('hello-debhelper')
+ self._check_repo_state(repo, 'master', ['master', 'pristine-tar', 'upstream'])
+ commits, expected = len(repo.get_commits()), 2
+ commits, expected = len(repo.get_commits(until='pristine-tar')), 1
+ ok_(commits == expected, "Found %d pristine-tar commits instead of %d" % (commits, expected))
+ eq_(repo.ls_tree('pristine-tar'), {b'hello-debhelper_2.8.orig.tar.gz.delta',
+ b'hello-debhelper_2.8.orig.tar.gz.id',
+ b'hello-debhelper_2.8.orig.tar.gz.asc'})