1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
#!/usr/bin/perl @files = glob('FS/*.pm'); foreach (@files) { # warn $_; chomp; s/^FS\///; $f=$_; $f=~s/pm$/t/; $m=$_; $m=~s/\.pm$//; open(TEST,">t/$f"); print "t/$f\n"; print TEST 'BEGIN { $| = 1; print "1..1\n" }'. "\n". 'END {print "not ok 1\n" unless $loaded;}'. "\n". "use FS::$m;\n". '$loaded=1;'. "\n". 'print "ok 1\n";'. "\n" ; close TEST; }