diff options
| author | fukachan <fukachan> | 2004-03-28 13:15:07 +0000 |
|---|---|---|
| committer | fukachan <fukachan> | 2004-03-28 13:15:07 +0000 |
| commit | bce076995be2fac2f45c66dd62e55aa366b929d9 (patch) | |
| tree | f6bd7286915e6df880e27e8f89439b3ff31321ce | |
| parent | 7336b91485a95185e6effc67fc715ec7eb93897f (diff) | |
| download | fml8-bce076995be2fac2f45c66dd62e55aa366b929d9.tar.gz fml8-bce076995be2fac2f45c66dd62e55aa366b929d9.tar.bz2 fml8-bce076995be2fac2f45c66dd62e55aa366b929d9.zip | |
test of Mail::Message::summary
| -rwxr-xr-x | regress/message/summary.pl | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/regress/message/summary.pl b/regress/message/summary.pl new file mode 100755 index 00000000..7e3f08c0 --- /dev/null +++ b/regress/message/summary.pl @@ -0,0 +1,34 @@ +#!/usr/bin/env perl +#-*- perl -*- +# +# Copyright (C) 2004 Ken'ichi Fukamachi +# All rights reserved. This program is free software; you can +# redistribute it and/or modify it under the same terms as Perl itself. +# +# $FML: basic_io.pl,v 1.5 2002/04/18 14:18:09 fukachan Exp $ +# + +use strict; +use Carp; +use lib qw(../../cpan/lib); +use Mail::Message; + +my $test_mode = $ENV{'test_mode'} ? 1 : 0; + +my $tmp = "/tmp/buf$$"; + +for my $f (@ARGV) { + print "// $f\n"; + + my $fh = new FileHandle $f; + my $wh = new FileHandle "> $tmp"; + my $msg = Mail::Message->parse( { fd => $fh } ); + + print $msg->one_line_summary($wh); + print "\n"; + print "\n"; +} + +unlink $tmp; + +exit 0; |
