I've made a new patch that does not require TAP::Harness 3.x, and uses a
Rakudo test with a call to run() to run the Parrot test which loads the
bytecode.
>From 039c18b01b2c12b95de560c5a26bdc7ac9dd7a32 Mon Sep 17 00:00:00 2001
From: Duke Leto <jonat...@leto.net>
Date: Wed, 9 Jun 2010 13:44:41 -0700
Subject: [PATCH] Add test for loading perl6.pbc bytecode

---
 build/Makefile.in      |    2 +-
 t/02-embed/01-load.pir |   29 +++++++++++++++++++++++++++++
 t/02-embed/01-load.t   |    3 +++
 3 files changed, 33 insertions(+), 1 deletions(-)
 create mode 100644 t/02-embed/01-load.pir
 create mode 100644 t/02-embed/01-load.t

diff --git a/build/Makefile.in b/build/Makefile.in
index 48eea9b..62606c0 100644
--- a/build/Makefile.in
+++ b/build/Makefile.in
@@ -395,7 +395,7 @@ test    : coretest
 fulltest: coretest spectest
 
 coretest: Test.pir $(PERL6_EXE)
-	$(PERL) t/harness t/00-parrot t/01-sanity
+	PARROT=$(PARROT) $(PERL) t/harness t/00-parrot t/01-sanity t/02-embed
 
 # Run the spectests that we know work.
 spectest_regression: spectest
diff --git a/t/02-embed/01-load.pir b/t/02-embed/01-load.pir
new file mode 100644
index 0000000..948ed25
--- /dev/null
+++ b/t/02-embed/01-load.pir
@@ -0,0 +1,29 @@
+=head1 NAME
+
+t/02-embed/01-load.pir - Tests loading of bytecode
+
+=head1 SYNOPSIS
+
+    % parrot t/02-embed/01-load.pir
+
+=head1 DESCRIPTION
+
+Tests the loading of perl6.pbc . This file is used by t/02-embed/01-load.t
+
+=cut
+
+.sub 'main' :main
+    .include 'test_more.pir'
+
+    plan(1)
+
+    test_load()
+.end
+
+.sub test_load
+    lives_ok(<<'CODE',"can load_bytecode perl6.pbc")
+.sub main
+    load_bytecode "perl6.pbc"
+.end
+CODE
+.end
diff --git a/t/02-embed/01-load.t b/t/02-embed/01-load.t
new file mode 100644
index 0000000..709a5f3
--- /dev/null
+++ b/t/02-embed/01-load.t
@@ -0,0 +1,3 @@
+use v6;
+my $parrot = %*ENV{'PARROT'};
+run("$parrot t/02-embed/01-load.pir");
-- 
1.7.0.4

Reply via email to