[libconfig-model-lcdproc-perl] 02/05: added tests for driver-path tweaking
dod at debian.org
dod at debian.org
Thu Jan 16 20:32:24 UTC 2014
This is an automated email from the git hooks/post-receive script.
dod pushed a commit to branch master
in repository libconfig-model-lcdproc-perl.
commit bb5fb65afb1c15bd1e65c54af69ce95ffcd6d88c
Author: Dominique Dumont <dod at debian.org>
Date: Sat Jan 11 16:36:22 2014 +0100
added tests for driver-path tweaking
---
debian/patches/series | 1 +
debian/patches/test-driver-path-default | 56 +++++++++++++++++++++++++++++++++
2 files changed, 57 insertions(+)
diff --git a/debian/patches/series b/debian/patches/series
index e1036cf..f2d8bdf 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,2 @@
tweak-defaults
+test-driver-path-default
diff --git a/debian/patches/test-driver-path-default b/debian/patches/test-driver-path-default
new file mode 100644
index 0000000..d1c725f
--- /dev/null
+++ b/debian/patches/test-driver-path-default
@@ -0,0 +1,56 @@
+--- a/t/model_tests.d/lcdd-test-conf.pl
++++ b/t/model_tests.d/lcdd-test-conf.pl
+@@ -13,33 +13,47 @@
+ $model_to_test = "LCDd" ;
+
+ my @fix_warnings ;
++my $triplet = `dpkg-architecture -qDEB_HOST_MULTIARCH`;
++chomp $triplet;
++my $std_path = "/usr/lib/$triplet/lcdproc/" ;
++my $path = $std_path;
+
+-push @fix_warnings,
++if (! -d $std_path) {
++ $path = "/tmp/" ;
++ push @fix_warnings,
+ (
+ #load_warnings => [ qr/code check returned false/ ],
+- load => "server DriverPath=/tmp/" , # just a work-around
+- )
+- unless -d '/usr/lib/lcdproc/' ;
++ load => "server DriverPath=$path" , # just a work-around
++ );
++}
+
+ @tests = (
+ { # t0
+- check => {
++ check => [
+ 'server Hello:0', qq!" Bienvenue"! ,
+ 'server Hello:1', qq(" LCDproc et Config::Model!") ,
+ 'server Driver', 'curses',
++ 'server DriverPath', { mode => 'standard', value => $std_path },
++ 'server DriverPath', $path ,
+ 'curses Size', '20x2',
+- },
++ ],
+ @fix_warnings ,
++ apply_fix => 1,
++ load_warnings => [ qr/missing DriverPath dir/],
+ errors => [
+ # qr/value 2 > max limit 0/ => 'fs:"/var/chroot/lenny-i386/dev" fs_passno=0' ,
+ ],
+ },
+ { #test upgrade from raw lcdproc 0.5.5
+ name => 'LDCd-0.5.5',
++ load_warnings => [ qr/missing DriverPath dir/],
++ apply_fix => 1,
+ load_check => 'skip'
+ },
+ { # likewise for lcdproc 0.5.6
+ name => 'LDCd-0.5.6',
++ load_warnings => [ qr/missing DriverPath dir/],
++ apply_fix => 1,
+ load_check => 'skip'
+ },
+
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-perl/packages/libconfig-model-lcdproc-perl.git
More information about the Pkg-perl-cvs-commits
mailing list