[libconfig-model-dpkg-perl] 01/07: test that struct_to_dep can return undef

dod at debian.org dod at debian.org
Mon Aug 21 17:54:31 UTC 2017


This is an automated email from the git hooks/post-receive script.

dod pushed a commit to branch master
in repository libconfig-model-dpkg-perl.

commit 59fa691a4498317336b4302a93e5f6f4c2ffaf26
Author: Dominique Dumont <dod at debian.org>
Date:   Fri Aug 18 19:30:14 2017 +0200

    test that struct_to_dep can return undef
---
 t/dependency-check.t | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/t/dependency-check.t b/t/dependency-check.t
index 9eabcde..de8845c 100644
--- a/t/dependency-check.t
+++ b/t/dependency-check.t
@@ -142,6 +142,7 @@ my $c_unit = $unit->config_root ;
 my $dep_value = $c_unit->grab("binary:dummy Depends:0");
 
 my @struct_2_dep = (
+    [{}] => undef,
     [{ name => 'foo' }] => 'foo',
     [{ name => 'foo' }, { name => 'bar'}] => 'foo | bar',
     [{ name =>  'foo', dep => [ '>=' , '2.15']}] => 'foo (>= 2.15)',
@@ -164,7 +165,7 @@ while (@struct_2_dep) {
     is(
         $dep_value->struct_to_dep(@$data),
         $str,
-        "test struct_to_dep -> $str"
+        'test struct_to_dep -> "'. ( $str // '<undef>' ) . '"'
     ) ;
 }
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libconfig-model-dpkg-perl.git



More information about the Pkg-perl-cvs-commits mailing list