Changeset 32 for t/01basic.t
- Timestamp:
- 02/16/05 18:48:28 (4 years ago)
- svk:copy_cache_prev:
- 1041
- Files:
-
- 1 modified
-
t/01basic.t (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
t/01basic.t
r31 r32 1 #!/usr/bin/perl 1 use v6; 2 2 3 use FindBin; 4 use Config; 5 use File::Spec; 3 =pod 6 4 7 chdir (File::Spec->catdir($FindBin::Bin, File::Spec->updir)); 8 my $pugs = File::Spec->catfile(File::Spec->curdir, "pugs$Config{_exe}"); 5 This is a test file. Whee! 9 6 10 system($pugs, -e => '"1..2\nok 1 # Welcome to Pugs!\n"'); 7 =cut 11 8 12 open PUGS, "| $pugs" or die "Cannot pipe out to $pugs: $!";13 print PUGS << '.';14 sub cool { fine($_) ~ " # We've got " ~ toys }; 15 sub fine { "ok " ~ $_ }; 16 sub toys { "fun and games!\n" }; 17 cool 2 18 . 19 close PUGS; 9 say "1..2"; 10 say "ok 1 # Welcome to Pugs!"; 11 12 sub cool { fine($_) ~ " # We've got " ~ toys } 13 sub fine { "ok " ~ $_ } 14 sub toys { "fun and games!" } 15 16 say cool 2 # and that's it, folks!
