From: Alexander Hartmaier Date: Wed, 21 Nov 2012 08:32:25 +0000 (+0100) Subject: fixed test failures in t/[rest,rpc]/item.t on newer HTTP::Message versions X-Git-Tag: 2.004004~4 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Controller-DBIC-API.git;a=commitdiff_plain;h=7dccc5deaababe588c4840eede41edd4b9d33bd6 fixed test failures in t/[rest,rpc]/item.t on newer HTTP::Message versions --- diff --git a/Changes b/Changes index c809938..d6fe455 100644 --- a/Changes +++ b/Changes @@ -1,6 +1,7 @@ Revision history for Catalyst-Controller-DBIC-API: {{ $dist->version }} {{ $NEXT }} +- Fixed test failures in t/[rest,rpc]/item.t on newer HTTP::Message versions 2.004003 2011-12-19 14:41:59 Europe/Vienna - Fixed test failure in generic.t with Moose > 2.02 diff --git a/t/rest/item.t b/t/rest/item.t index dbc5e60..dea2b88 100644 --- a/t/rest/item.t +++ b/t/rest/item.t @@ -23,7 +23,7 @@ my $artist_view_url = "$base/api/rest/artist/"; { my $id = 1; my $req = - GET( $artist_view_url . $id, undef, 'Accept' => 'application/json' ); + GET( $artist_view_url . $id, 'Accept' => 'application/json' ); $mech->request($req); cmp_ok( $mech->status, '==', 200, 'open attempt okay' ); my %expected_response = @@ -39,7 +39,7 @@ my $artist_view_url = "$base/api/rest/artist/"; { my $id = 5; my $req = - GET( $artist_view_url . $id, undef, 'Accept' => 'application/json' ); + GET( $artist_view_url . $id, 'Accept' => 'application/json' ); $mech->request($req); cmp_ok( $mech->status, '==', 400, 'open attempt not ok' ); my $response = $json->decode( $mech->content ); @@ -57,7 +57,7 @@ my $track_view_url = "$base/api/rest/track/"; { my $id = 9; my $req = - GET( $track_view_url . $id, undef, 'Accept' => 'application/json' ); + GET( $track_view_url . $id, 'Accept' => 'application/json' ); $mech->request($req); cmp_ok( $mech->status, '==', 200, 'got track with datetime object okay' ); my %expected_response = @@ -72,7 +72,7 @@ my $track_view_url = "$base/api/rest/track/"; { my $req = - GET( $artist_view_url . 'action_with_error', undef, 'Accept' => 'application/json' ); + GET( $artist_view_url . 'action_with_error', 'Accept' => 'application/json' ); $mech->request($req); cmp_ok( $mech->status, '==', 404, 'action returned error 404' ); my $response = $json->decode( $mech->content ); diff --git a/t/rpc/item.t b/t/rpc/item.t index b322956..12eb5bb 100644 --- a/t/rpc/item.t +++ b/t/rpc/item.t @@ -22,8 +22,7 @@ my $artist_view_url = "$base/api/rpc/artist/id/"; { my $id = 1; - my $req = - GET( $artist_view_url . $id, undef, 'Accept' => 'application/json' ); + my $req = GET( $artist_view_url . $id, 'Accept' => 'application/json' ); $mech->request($req); cmp_ok( $mech->status, '==', 200, 'open attempt okay' ); my %expected_response = @@ -38,8 +37,7 @@ my $artist_view_url = "$base/api/rpc/artist/id/"; { my $id = 5; - my $req = - GET( $artist_view_url . $id, undef, 'Accept' => 'application/json' ); + my $req = GET( $artist_view_url . $id, 'Accept' => 'application/json' ); $mech->request($req); cmp_ok( $mech->status, '==', 400, 'open attempt not ok' ); my $response = $json->decode( $mech->content );