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