Skip to content
This repository has been archived by the owner on Jun 9, 2018. It is now read-only.

Commit

Permalink
run parrot in current directory
Browse files Browse the repository at this point in the history
  • Loading branch information
fperrad committed Sep 4, 2009
1 parent f381ee3 commit f72e19c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 110 deletions.
9 changes: 4 additions & 5 deletions t/Parrot/Test/WMLScript.pm
Expand Up @@ -47,6 +47,7 @@ foreach my $func ( keys %language_test_map ) {
my $function = $options{function} || 'main';
my $params = $options{params} || q{};

my $parrot = File::Spec->catfile( $self->{relpath}, $self->{parrot} );
# flatten filenames (don't use directories)
my $lang_fn = File::Spec->rel2abs( Parrot::Test::per_test( '.wmls', $count ) );
my $bin_fn = File::Spec->rel2abs( Parrot::Test::per_test( '.wmlsc', $count ) );
Expand All @@ -57,22 +58,20 @@ foreach my $func ( keys %language_test_map ) {

Parrot::Test::run_command(
"wmlsc $cflags ${lang_fn}",
CD => $self->{relpath},
STDOUT => $out_fn,
STDERR => $out_fn,
);

my @test_prog = (

# "wmlsc $cflags ${lang_fn}",
# "$self->{parrot} languages/WMLScript/wmls2pir.pir ${bin_fn}",
"$self->{parrot} languages/wmlscript/wmlsi.pir ${bin_fn} $function $params",
# "wmlsc $cflags $lang_fn",
# "$parrot wmls2pir.pir $bin_fn",
"$parrot wmlsi.pir $bin_fn $function $params",
);

# STDERR is written into same output file
my $exit_code = Parrot::Test::run_command(
\@test_prog,
CD => $self->{relpath},
STDOUT => $out_fn,
STDERR => $out_fn,
);
Expand Down
8 changes: 4 additions & 4 deletions t/pragmas.t
Expand Up @@ -35,7 +35,7 @@ Hello World!
OUT

language_output_is( 'WMLScript', <<'CODE', <<'OUT', 'use url' );
use url OtherScript "languages/wmlscript/t/pragmas_1.wmlsc";
use url OtherScript "t/pragmas_1.wmlsc";
extern function main()
{
Expand All @@ -46,7 +46,7 @@ Hello World!
OUT

language_output_like( 'WMLScript', <<'CODE', <<'OUT', 'unable to load' );
use url OtherScript "languages/wmlscript/t/pragmas_x.wmlsc";
use url OtherScript "t/pragmas_x.wmlsc";
extern function main()
{
Expand All @@ -57,7 +57,7 @@ CODE
OUT

language_output_like( 'WMLScript', <<'CODE', <<'OUT', 'verification failed' );
use url OtherScript "languages/wmlscript/t/pragmas_1.out";
use url OtherScript "t/pragmas_1.out";
extern function main()
{
Expand All @@ -68,7 +68,7 @@ CODE
OUT

language_output_like( 'WMLScript', <<'CODE', <<'OUT', 'external function not found' );
use url OtherScript "languages/wmlscript/t/pragmas_1.wmlsc";
use url OtherScript "t/pragmas_1.wmlsc";
extern function main()
{
Expand Down
101 changes: 0 additions & 101 deletions t/runtime.t

This file was deleted.

0 comments on commit f72e19c

Please sign in to comment.