3 # This file is part of Acme::Tie::Eleet.
4 # Copyright (c) 2001-2007 Jerome Quelin, all rights reserved.
6 # This program is free software; you can redistribute it and/or modify
7 # it under the same terms as Perl itself.
15 #-----------------------------------#
17 #-----------------------------------#
21 # use POSIX qw(tmpnam);
24 # BEGIN { plan tests => 4 };
25 BEGIN { plan tests => 2 };
28 require Acme::Tie::Eleet;
34 # my $file = tmpnam();
47 #------------------------------#
49 #------------------------------#
51 # # Beginning of sentence.
52 # open OUT, ">$file" or die "Unable to create temporary file: $!";
53 # tie *OUT, 'Acme::Tie::Eleet', *OUT, @opts, add_before=>100;
56 # open IN, "<$file" or die "Unable to open temporary file: $!";
58 # ok($line, qr/^(?!eleet)/);
61 # open OUT, ">$file" or die "Unable to create temporary file: $!";
62 # tie *OUT, 'Acme::Tie::Eleet', *OUT, @opts, add_after=>100;
65 # open IN, "<$file" or die "Unable to open temporary file: $!";
67 # ok($line, qr/(?!eleet$)/);
72 #------------------------------#
74 #------------------------------#
76 # Beginning of sentence.
77 tie $line, 'Acme::Tie::Eleet', @opts, add_before=>100;
79 ok($line, qr/^(?!eleet)/);
83 tie $line, 'Acme::Tie::Eleet', @opts, add_after=>100;
85 ok($line, qr/(?!eleet$)/);