150 lines
3.4 KiB
Diff
150 lines
3.4 KiB
Diff
diff -up CGI-4.27/t/cgi.t.orig CGI-4.27/t/cgi.t
|
|
--- CGI-4.27/t/cgi.t.orig 2016-03-02 08:43:05.000000000 +0100
|
|
+++ CGI-4.27/t/cgi.t 2016-03-02 15:52:50.825729857 +0100
|
|
@@ -6,7 +6,6 @@ use strict;
|
|
use warnings;
|
|
|
|
use Test::More tests => 25;
|
|
-use Test::Deep;
|
|
|
|
use CGI ();
|
|
|
|
@@ -27,11 +26,15 @@ is( $q->PrintHeader,$q->header,'PrintHea
|
|
is( $q->HtmlTop,$q->start_html,'HtmlTop' );
|
|
is( $q->HtmlBot,$q->end_html,'HtmlBot' );
|
|
|
|
-cmp_deeply(
|
|
+SKIP: {
|
|
+ skip 'Test::Deep module is not available', 1 unless
|
|
+ eval 'use Test::Deep 0.11; 1';
|
|
+ cmp_deeply(
|
|
[ my @params = CGI::SplitParam( "foo\0bar" ) ],
|
|
[ qw/ foo bar /],
|
|
'SplitParam'
|
|
-);
|
|
+ );
|
|
+}
|
|
|
|
ok( $q->MethGet,'MethGet' );
|
|
ok( ! $q->MethPost,'MethPost' );
|
|
@@ -60,13 +63,17 @@ $CGI::CLOSE_UPLOAD_FILES = 0;
|
|
ok( $q->close_upload_files( 1 ),'close_upload_files' );
|
|
is( $CGI::CLOSE_UPLOAD_FILES,1,' ... sets $CGI::CLOSE_UPLOAD_FILES' );
|
|
|
|
-cmp_deeply(
|
|
+SKIP: {
|
|
+ skip 'Test::Deep module is not available', 1 unless
|
|
+ eval 'use Test::Deep 0.11; 1';
|
|
+ cmp_deeply(
|
|
$q->default_dtd,
|
|
[
|
|
'-//W3C//DTD HTML 4.01 Transitional//EN',
|
|
'http://www.w3.org/TR/html4/loose.dtd'
|
|
],
|
|
'default_dtd'
|
|
-);
|
|
+ );
|
|
+}
|
|
|
|
ok( ! $q->private_tempfiles,'private_tempfiles' );
|
|
diff -up CGI-4.27/t/param_list_context.t.orig CGI-4.27/t/param_list_context.t
|
|
--- CGI-4.27/t/param_list_context.t.orig 2016-03-02 08:48:20.000000000 +0100
|
|
+++ CGI-4.27/t/param_list_context.t 2016-03-02 15:52:50.825729857 +0100
|
|
@@ -4,7 +4,7 @@ use strict;
|
|
use warnings;
|
|
|
|
use Test::More;
|
|
-use Test::Deep;
|
|
+
|
|
use Test::Warn;
|
|
|
|
use CGI ();
|
|
@@ -43,11 +43,15 @@ warnings_are
|
|
" ... but we only warn once",
|
|
;
|
|
|
|
-cmp_deeply(
|
|
+SKIP: {
|
|
+ skip 'Test::Deep module is not available', 1 unless
|
|
+ eval 'use Test::Deep 0.11; 1';
|
|
+ cmp_deeply(
|
|
[ sort @params ],
|
|
[ qw/ checkers chess / ],
|
|
'CGI::param()',
|
|
-);
|
|
+ );
|
|
+}
|
|
|
|
warnings_are
|
|
{ @params = $q->multi_param('game') }
|
|
@@ -55,11 +59,15 @@ warnings_are
|
|
"no warnings calling multi_param"
|
|
;
|
|
|
|
-cmp_deeply(
|
|
+SKIP: {
|
|
+ skip 'Test::Deep module is not available', 1 unless
|
|
+ eval 'use Test::Deep 0.11; 1';
|
|
+ cmp_deeply(
|
|
[ sort @params ],
|
|
[ qw/ checkers chess / ],
|
|
'CGI::multi_param'
|
|
-);
|
|
+ );
|
|
+}
|
|
|
|
$CGI::LIST_CONTEXT_WARN = 0;
|
|
|
|
diff -up CGI-4.27/t/request.t.orig CGI-4.27/t/request.t
|
|
--- CGI-4.27/t/request.t.orig 2016-03-02 08:16:46.000000000 +0100
|
|
+++ CGI-4.27/t/request.t 2016-03-02 15:52:50.825729857 +0100
|
|
@@ -4,7 +4,6 @@ use strict;
|
|
use warnings;
|
|
|
|
use Test::More tests => 71;
|
|
-use Test::Deep;
|
|
|
|
use CGI ();
|
|
use Config;
|
|
@@ -117,7 +116,9 @@ $q->_reset_globals;
|
|
is_deeply [ sort $q->$_( 'keywords' ) ], [ qw/ dragon tiger / ],
|
|
"$_ keywords" for qw/ param url_param /;
|
|
|
|
- {
|
|
+ SKIP: {
|
|
+ skip 'Test::Deep module is not available', 2 unless
|
|
+ (eval 'use Test::Deep 0.11; 1');
|
|
$^W++;
|
|
|
|
CGI::_reset_globals;
|
|
diff -up CGI-4.27/t/util.t.orig CGI-4.27/t/util.t
|
|
--- CGI-4.27/t/util.t.orig 2015-12-15 18:12:19.000000000 +0100
|
|
+++ CGI-4.27/t/util.t 2016-03-02 15:52:50.825729857 +0100
|
|
@@ -6,7 +6,6 @@
|
|
$| = 1;
|
|
|
|
use Test::More tests => 80;
|
|
-use Test::Deep;
|
|
use Config;
|
|
use_ok ( 'CGI::Util', qw(
|
|
escape
|
|
@@ -68,6 +67,10 @@ for ( 1 .. 20 ) {
|
|
%args,
|
|
);
|
|
|
|
+ SKIP: {
|
|
+ skip 'Test::Deep module is not available', 1 unless
|
|
+ eval 'use Test::Deep 0.11; 1';
|
|
+
|
|
cmp_deeply(
|
|
[ @ordered ],
|
|
[
|
|
@@ -83,6 +86,7 @@ for ( 1 .. 20 ) {
|
|
],
|
|
'rearrange not sensitive to hash key ordering'
|
|
);
|
|
+ }
|
|
}
|
|
|
|
ok( CGI::Util::utf8_chr( "1",1 ),'utf8_chr' );
|