summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorMichael Vogt <mvo@debian.org>2011-03-21 16:30:25 +0100
committerMichael Vogt <mvo@debian.org>2011-03-21 16:30:25 +0100
commitd902f6e33493be74d7908b859d6272a7892f635c (patch)
treea4f1112cffd64ee0cae978d636854b5bbb98e8ad /tests
parente3ebbfe848d3d03baaf969374ac55641873bb798 (diff)
downloadpython-apt-d902f6e33493be74d7908b859d6272a7892f635c.tar.gz
* python/arfile.cc, apt/debfile.py:
- add support for .xz archives * tests/test_debfile.py: - add test for xz compression
Diffstat (limited to 'tests')
-rw-r--r--tests/data/test_debs/data-tar-xz.debbin0 -> 626 bytes
-rw-r--r--tests/test_debfile.py5
2 files changed, 5 insertions, 0 deletions
diff --git a/tests/data/test_debs/data-tar-xz.deb b/tests/data/test_debs/data-tar-xz.deb
new file mode 100644
index 00000000..fc15f597
--- /dev/null
+++ b/tests/data/test_debs/data-tar-xz.deb
Binary files differ
diff --git a/tests/test_debfile.py b/tests/test_debfile.py
index 712c4958..32e52ddb 100644
--- a/tests/test_debfile.py
+++ b/tests/test_debfile.py
@@ -112,6 +112,11 @@ Description: testpackage for gdebi - contains usr/bin/binary for file reading
content = deb.control_content("control")
self.assertEqual(content, needle)
+ def test_xz_data(self):
+ deb = apt.debfile.DebPackage("./data/test_debs/data-tar-xz.deb")
+ self.assertEqual(deb.filelist, ["./", "usr/", "usr/bin/"])
+
+
if __name__ == "__main__":
#logging.basicConfig(level=logging.DEBUG)
unittest.main()