From 28ddc800b720c62fe2acc12e2bce88c0b4efaad8 Mon Sep 17 00:00:00 2001 From: Urban Müller Date: Mon, 10 Aug 2015 16:04:53 +0200 Subject: php 5.3 compatibility --- tests/it_url.t | 10 +++++----- tests/it_url_slow.t | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'tests') diff --git a/tests/it_url.t b/tests/it_url.t index 0b81881..514593c 100755 --- a/tests/it_url.t +++ b/tests/it_url.t @@ -185,7 +185,7 @@ handle_server( $output = handle_server( ok( - !it_url::get(U('http://localhost:8000/redirect_loop', 'num' => 10)), + !it_url::get(U('http://localhost:8000/redirect_loop', array('num' => 10))), 'it_url::get() handles redirect loop' ) ); @@ -198,7 +198,7 @@ if (!ok( $output = handle_server( ok( - !it_url::get('url' => 'http://localhost:8000/does_not_exist', 'retries' => 4), + !it_url::get(array('url' => 'http://localhost:8000/does_not_exist', 'retries' => 4)), 'it_url::get() retries on empty response' ) ); @@ -210,7 +210,7 @@ if (!ok( handle_server( is( - it_url::get(U('http://localhost:8000/get_server_value', 'key' => 'HTTP_HOST')), + it_url::get(U('http://localhost:8000/get_server_value', array('key' => 'HTTP_HOST'))), 'localhost:8000', 'it_url::get() sets correct Host header' ) @@ -218,7 +218,7 @@ handle_server( handle_server( is( - it_url::get(U('http://localhost:8000/get_server_value', 'key' => 'HTTP_ACCEPT_LANGUAGE')), + it_url::get(U('http://localhost:8000/get_server_value', array('key' => 'HTTP_ACCEPT_LANGUAGE'))), T_lang(), 'it_url::get() sets correct Accept-Language header' ) @@ -226,7 +226,7 @@ handle_server( handle_server( ok( - it::match('Mozilla', it_url::get(U('http://localhost:8000/get_server_value', 'key' => 'HTTP_USER_AGENT'))), + it::match('Mozilla', it_url::get(U('http://localhost:8000/get_server_value', array('key' => 'HTTP_USER_AGENT')))), 'it_url::get() sets User-Agent containing Mozilla' ) ); diff --git a/tests/it_url_slow.t b/tests/it_url_slow.t index 22aae10..1dc3d78 100755 --- a/tests/it_url_slow.t +++ b/tests/it_url_slow.t @@ -53,7 +53,7 @@ if (!$res || !$res2) handle_server( ok( - it_url::get(U('http://localhost:8000/repeat', 'string' => "abc", 'num' => 1024 * 1024)) == str_repeat("abc", 1024 * 1024), + it_url::get(U('http://localhost:8000/repeat', 'string' => "abc", array('num' => 1024 * 1024))) == str_repeat("abc", 1024 * 1024), 'it_url::get() handles large response' ) ); -- cgit v1.2.3