tests now pass!
[catagits/Catalyst-Devel.git] / t / check_testapp_the_same.t
CommitLineData
bec5b08a 1use strict;
2use warnings;
3
4use FindBin qw/$Bin/;
5
6use Test::More tests => 3;
7
c10c0e84 8## find out where catalyst.pl is
bec5b08a 9my $cat = `which catalyst.pl`;
10chomp($cat);
c10c0e84 11
12## remove any existing test apps
bec5b08a 13is system("rm -rf $Bin/../TestAppForComparison"), 0 or BAIL_OUT;
bec5b08a 14
c10c0e84 15## create a new test app to compare to
16is system("cd $Bin/../; $^X -I$Bin/../lib $cat TestAppForComparison"), 0 or BAIL_OUT;
17
18SKIP: {
19
20 my $diff;
21 eval {
6709d9fb 22 $diff = `diff -urNB -x .svn -x Changes $Bin/TestAppForComparison $Bin/../TestAppForComparison`;
c10c0e84 23 };
24
25 skip "no diff program installed, skipping", 1 if $@;
26
27 ok !length($diff), 'Generated same TestApp', or warn($diff);
28
29}