A few fixes to get the JSON test working.
[catagits/Gitalist.git] / t / rss.t
diff --git a/t/rss.t b/t/rss.t
index e603c08..c9c3804 100644 (file)
--- a/t/rss.t
+++ b/t/rss.t
@@ -1,22 +1,16 @@
 #!/usr/bin/env perl
-use strict;
-use warnings;
-use Test::More;
 use FindBin qw/$Bin/;
-
-BEGIN {
-    $ENV{GITALIST_CONFIG} = $Bin;
-    $ENV{GITALIST_REPO_DIR} = '';
-    use_ok 'Catalyst::Test', 'Gitalist';
-}
+BEGIN { do "$FindBin::Bin/../script/env" or die $@ }
+use lib "$Bin/lib";
+use TestGitalist;
 
 my $res = request('/repo1/rss');
 ok $res->is_success;
-
+is $res->content_type, 'application/rss+xml';
 like $res->content, qr{link>http://localhost/repo1</link};
 like $res->content, qr{description>some test repository</description};
 like $res->content, qr{title>add dir1/file2</title};
 like $res->content, qr{description>add dir1/file2</description};
-like $res->content, qr{guid isPermaLink="true">http://localhost/repo1/36c6c6708b8360d7023e8a1649c45bcf9b3bd818</guid};
+like $res->content, qr{guid isPermaLink="true">http://localhost/repo1/36c6c6708b8360d7023e8a1649c45bcf9b3bd818/commit</guid};
 
 done_testing;