From 8ae9672cf34217fabd6ec3d69692a30c3c3e6c3c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Oudot?= Date: Thu, 3 Oct 2013 10:48:52 +0000 Subject: [PATCH] Test defaultValuesInit (#558) --- .../t/05-Lemonldap-NG-Handler-Vhost.t | 24 ++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/lemonldap-ng-handler/t/05-Lemonldap-NG-Handler-Vhost.t b/lemonldap-ng-handler/t/05-Lemonldap-NG-Handler-Vhost.t index 41c11840f..a99c8628c 100644 --- a/lemonldap-ng-handler/t/05-Lemonldap-NG-Handler-Vhost.t +++ b/lemonldap-ng-handler/t/05-Lemonldap-NG-Handler-Vhost.t @@ -7,7 +7,7 @@ package My::Package; -use Test::More tests => 4; +use Test::More tests => 5; BEGIN { use_ok('Lemonldap::NG::Handler::Vhost'); @@ -23,6 +23,28 @@ our @ISA = qw( Lemonldap::NG::Handler::Vhost Lemonldap::NG::Handler::Simple ); my $h; $h = bless {}, 'My::Package'; +open STDERR, '>/dev/null'; + +ok( + $h->defaultValuesInit( + { + https => 0, + port => 0, + maintenance => 0, + vhostOptions => { + www1 => { + vhostHttps => 1, + vhostPort => 443, + vhostMaintenance => 1, + vhostAliases => 'www2 www3', + + } + }, + } + ), + 'defaultValuesInit' +); + ok( $h->locationRulesInit( {