# HG changeset patch # User root@weber.ctq.de # Date 1312199008 -7200 # Node ID a223c778af509256c5a6c2eeba61ef4d5f4c89ba # Parent 0fda055e6e77aa5b1c0a42d747f291cda4010192 added syntax test diff -r 0fda055e6e77 -r a223c778af50 t/000-syntax.t --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/t/000-syntax.t Mon Aug 01 13:43:28 2011 +0200 @@ -0,0 +1,22 @@ +use 5.010; +use strict; +use warnings; +use Test::More; +use File::Find; +use File::Temp; + +my @files; +find(sub { + -f -x or return; + push @files => $File::Find::name; +}, "bin"); + +plan tests => scalar @files; + +my $tmp = File::Temp->new; + +foreach (@files) { + system("perl -c $_ 2>$tmp"); + seek($tmp, 0, 0); + is($? => 0, "syntax $_ OK") or diag join "" => <$tmp>; +}