X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Action-Serialize-Data-Serializer.git;a=blobdiff_plain;f=t%2Fyaml-html.t;fp=t%2Fyaml-html.t;h=0000000000000000000000000000000000000000;hp=bf9bf1070450bff740aead46c04b35b302a7d8d7;hb=79025f72c27ba313b3c701cee238f84166f32f9e;hpb=f10c7e1c7eb3b4cb10401dbb86ca8db3dc38ced2 diff --git a/t/yaml-html.t b/t/yaml-html.t deleted file mode 100644 index bf9bf10..0000000 --- a/t/yaml-html.t +++ /dev/null @@ -1,42 +0,0 @@ -use strict; -use warnings; -use Test::More; -use YAML::Syck; -use FindBin; - -use lib ( "$FindBin::Bin/lib", "$FindBin::Bin/../lib" ); -use Test::Rest; - -BEGIN { - use_ok 'Catalyst::Test', 'Test::Serialize'; -} - -my $has_serializer = eval "require YAML::Syck"; -SKIP: { - skip "YAML::Syck not available", 3, unless $has_serializer; - - my $t = Test::Rest->new( 'content_type' => 'text/html' ); - - my $monkey_template = -"Test::Serialize
--- \nmonkey: likes chicken!\n
"; - my $mres = request( $t->get( url => '/monkey_get' ) ); - ok( $mres->is_success, 'GET the monkey succeeded' ); - is( $mres->content, $monkey_template, "GET returned the right data" ); - - my $post_data = { 'sushi' => 'is good for monkey', }; - my $mres_post = - request( $t->post( url => '/monkey_put', data => Dump($post_data) ) ); - ok( $mres_post->is_error, "POST to the monkey failed; no deserializer." ); - - # xss test - RT 63537 - my $xss_template = -"Test::Serialize
--- \nmonkey: likes chicken > sushi!\n
"; - my $xres = request( $t->get( url => '/xss_get' ) ); - ok( $xres->is_success, 'GET the xss succeeded' ); - is( $xres->content, $xss_template, "GET returned the right data" ); - - -} -1; - -done_testing;