Mercurial > hg > Applications > mh
comparison nkf-utf8/make_test.pl @ 12:441a2190cfae
Lion fix
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Sat, 21 Apr 2012 13:10:49 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
11:5cf052bee63d | 12:441a2190cfae |
---|---|
1 #!/usr/bin/perl | |
2 while ( <test_data/*.cmd> ) { | |
3 $file = $_; | |
4 $test = $file; $test =~ s/\.cmd$//; | |
5 $out = $test.".out"; $out = `cat $out`; | |
6 $in = $test.".in"; $in = `cat $in`; | |
7 $opt = `cat $file`; chomp($opt); | |
8 | |
9 $inpack = pack('u',$in); chomp($inpack); | |
10 $outpack = pack('u',$out); chomp($outpack); | |
11 | |
12 print << "EOFEOF"; | |
13 # $test | |
14 | |
15 \$example{'$test'} = unpack('u',<<'eofeof'); | |
16 $inpack | |
17 eofeof | |
18 | |
19 \$example{'$test.ans'} = unpack('u',<<'eofeof'); | |
20 $outpack | |
21 eofeof | |
22 | |
23 print "$test "; | |
24 \&test("\$nkf $opt",\$example{'$test'},\$example{'$test.ans'}); | |
25 EOFEOF | |
26 | |
27 } |