File tree Expand file tree Collapse file tree 3 files changed +46
-0
lines changed Expand file tree Collapse file tree 3 files changed +46
-0
lines changed Original file line number Diff line number Diff line change
1
+ use lib ' lib' , ' blib/lib' ;
2
+ use Inline::Python;
3
+
4
+ class Precomp::First { }
Original file line number Diff line number Diff line change
1
+ use lib ' t' ;
2
+ use Precomp::First;
3
+
4
+ class Precomp::Second { }
Original file line number Diff line number Diff line change
1
+ # !/usr/bin/env perl6
2
+
3
+ use v6 ;
4
+ use Test ;
5
+ use Inline::Python;
6
+
7
+ BEGIN {
8
+ % * ENV <PERL6LIB > = ' lib:blib/lib' ;
9
+ }
10
+
11
+ plan 2 ;
12
+
13
+ my $ ipc = CompUnit. new (' lib/Inline/Python.pm6' );
14
+ my $ already-precompiled = $ ipc . precomp-path. IO . e ;
15
+
16
+ if not $ already-precompiled {
17
+ $ ipc . precomp;
18
+ }
19
+
20
+ my $ first = CompUnit. new (' t/Precomp/First.pm6' );
21
+ my $ second = CompUnit. new (' t/Precomp/Second.pm6' );
22
+
23
+ ok $ first . precomp;
24
+ ok $ second . precomp;
25
+
26
+ # clean up
27
+ sub rmpp ($ cu ) {
28
+ unlink ($ cu . precomp-path);
29
+ }
30
+
31
+ rmpp($ first );
32
+ rmpp($ second );
33
+
34
+ if not $ already-precompiled {
35
+ rmpp($ ipc );
36
+ }
37
+
38
+ # vim: ft=perl6
You can’t perform that action at this time.
0 commit comments