From 11c117de3d421d0b9843f6fdfeea3933c3d47fe5 Mon Sep 17 00:00:00 2001 From: ivan Date: Mon, 16 Jun 2008 18:32:54 +0000 Subject: add debugging, properly export subs --- t/get-cryptssleay.t | 12 +++++------- t/get-netssleay.t | 11 ++++++----- t/post-cryptssleay.t | 12 +++++------- t/post-netssleay.t | 11 ++++++----- 4 files changed, 22 insertions(+), 24 deletions(-) (limited to 't') diff --git a/t/get-cryptssleay.t b/t/get-cryptssleay.t index 2b3babe..920f50a 100644 --- a/t/get-cryptssleay.t +++ b/t/get-cryptssleay.t @@ -5,17 +5,15 @@ use warnings; use Test::More; BEGIN { + plan( tests=>4 ); $Business::OnlinePayment::HTTPS::skip_NetSSLeay=1; $Business::OnlinePayment::HTTPS::skip_NetSSLeay=1; -} - -plan( tests=>4 ); - -use_ok 'Net::HTTPS::Any'; + use_ok 'Net::HTTPS::Any', 'https_get'; +}; #200 -my($content, $response, %headers) = Net::HTTPS::Any::https_get( +my($content, $response, %headers) = https_get( { 'host' => 'secure.sisd.com', 'port' => 443, 'path' => '/freeside/index.html', @@ -29,7 +27,7 @@ ok( length($content), 'Received content' ); #404 -my($content2, $response2, %headers2) = Net::HTTPS::Any::https_get( +my($content2, $response2, %headers2) = https_get( { 'host' => 'secure.sisd.com', 'port' => 443, 'path' => '/freeside/notfound.html', diff --git a/t/get-netssleay.t b/t/get-netssleay.t index 9c83a0f..d36111d 100644 --- a/t/get-netssleay.t +++ b/t/get-netssleay.t @@ -4,13 +4,14 @@ use strict; use warnings; use Test::More; -plan( tests=>4 ); - -use_ok 'Net::HTTPS::Any'; +BEGIN { + plan( tests=>4 ); + use_ok( 'Net::HTTPS::Any', qw( https_get ) ); +} #200 -my($content, $response, %headers) = Net::HTTPS::Any::https_get( +my($content, $response, %headers) = https_get( { 'host' => 'secure.sisd.com', 'port' => 443, 'path' => '/freeside/index.html', @@ -24,7 +25,7 @@ ok( length($content), 'Received content' ); #404 -my($content2, $response2, %headers2) = Net::HTTPS::Any::https_get( +my($content2, $response2, %headers2) = https_get( { 'host' => 'secure.sisd.com', 'port' => 443, 'path' => '/freeside/notfound.html', diff --git a/t/post-cryptssleay.t b/t/post-cryptssleay.t index 2ddda1b..2bf52ff 100644 --- a/t/post-cryptssleay.t +++ b/t/post-cryptssleay.t @@ -5,17 +5,15 @@ use warnings; use Test::More; BEGIN { + plan( tests=>4 ); $Business::OnlinePayment::HTTPS::skip_NetSSLeay=1; $Business::OnlinePayment::HTTPS::skip_NetSSLeay=1; -} - -plan( tests=>4 ); - -use_ok 'Net::HTTPS::Any'; + use_ok 'Net::HTTPS::Any', 'https_post'; +}; #200 -my($content, $response, %headers) = Net::HTTPS::Any::https_post( +my($content, $response, %headers) = https_post( { 'host' => 'secure.sisd.com', 'port' => 443, 'path' => '/freeside/index.html', @@ -29,7 +27,7 @@ ok( length($content), 'Received content' ); #404 -my($content2, $response2, %headers2) = Net::HTTPS::Any::https_get( +my($content2, $response2, %headers2) = https_post( { 'host' => 'secure.sisd.com', 'port' => 443, 'path' => '/freeside/notfound.html', diff --git a/t/post-netssleay.t b/t/post-netssleay.t index e8cb2fd..14fc98b 100644 --- a/t/post-netssleay.t +++ b/t/post-netssleay.t @@ -4,13 +4,14 @@ use strict; use warnings; use Test::More; -plan( tests=>4 ); - -use_ok 'Net::HTTPS::Any'; +BEGIN { + plan( tests=>4 ); + use_ok 'Net::HTTPS::Any', 'https_post'; +}; #200 -my($content, $response, %headers) = Net::HTTPS::Any::https_post( +my($content, $response, %headers) = https_post( { 'host' => 'secure.sisd.com', 'port' => 443, 'path' => '/freeside/index.html', @@ -24,7 +25,7 @@ ok( length($content), 'Received content' ); #404 -my($content2, $response2, %headers2) = Net::HTTPS::Any::https_get( +my($content2, $response2, %headers2) = https_post( { 'host' => 'secure.sisd.com', 'port' => 443, 'path' => '/freeside/notfound.html', -- cgit v1.2.1