diff options
author | Raphaël Hertzog <hertzog@debian.org> | 2010-06-28 08:45:01 +0200 |
---|---|---|
committer | Raphaël Hertzog <hertzog@debian.org> | 2010-06-28 08:45:01 +0200 |
commit | 2d7f7493c581f413a0586ba5a790f2306bcd655d (patch) | |
tree | cf63e0d66e057e3b2ea92201a12cdba701cb812c /scripts/t | |
parent | 8f576412d15d80e34859c254aa748d6acc606749 (diff) | |
download | dpkg-2d7f7493c581f413a0586ba5a790f2306bcd655d.tar.gz |
Dpkg::Changelog: fixed to cope properly with an entry of version "0"
The change of the boolean evaluation of Dpkg::Version introduced in
5b9f353b2940de751df47036608afbe71992d622 broke Dpkg::Changelog's ability
to correctly export an entry with a version of "0".
Add a non-regression test for this.
Diffstat (limited to 'scripts/t')
-rw-r--r-- | scripts/t/600_Dpkg_Changelog.t | 5 | ||||
-rw-r--r-- | scripts/t/600_Dpkg_Changelog/regressions | 3 |
2 files changed, 7 insertions, 1 deletions
diff --git a/scripts/t/600_Dpkg_Changelog.t b/scripts/t/600_Dpkg_Changelog.t index 5d3d531a5..81130a70e 100644 --- a/scripts/t/600_Dpkg_Changelog.t +++ b/scripts/t/600_Dpkg_Changelog.t @@ -25,6 +25,7 @@ BEGIN { + $no_err_examples * 2 + 26 # countme + 13 # fields + + 1 # regressions + 22; require Test::More; @@ -294,6 +295,10 @@ Xb-Userfield2: foobar ", "change items 2"); is($items[5], " * Update S-V.\n", "change items 3"); } + if ($file eq "$datadir/regressions") { + my $f = $changes->dpkg(); + is("$f->{Version}", "0", "version 0 correctly parsed"); + } SKIP: { skip("avoid spurious warning with only one entry", 2) diff --git a/scripts/t/600_Dpkg_Changelog/regressions b/scripts/t/600_Dpkg_Changelog/regressions index d0101804a..4c8ad308a 100644 --- a/scripts/t/600_Dpkg_Changelog/regressions +++ b/scripts/t/600_Dpkg_Changelog/regressions @@ -1,6 +1,7 @@ -re-gressions++1.2.3 (1.5-1) ALLOWED.chars-567+890; urgency=low +re-gressions++1.2.3 (0) ALLOWED.chars-567+890; urgency=low * Test allowed chars in package name and distribution name. (Closes: #361171) + * Test how version 0 is exported through methods. -- Frank Lichtenheld <frank@lichtenheld.de> Thu, 01 Jan 1970 00:00:00 +0000 |