File: 04create.t

package info (click to toggle)
libinline-perl 0.44-3
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 440 kB
  • ctags: 121
  • sloc: perl: 3,768; makefile: 38
file content (28 lines) | stat: -rw-r--r-- 489 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
use File::Spec;
use lib (File::Spec->catdir(File::Spec->curdir(),'blib','lib'), File::Spec->curdir());
use strict;
use Test;
use diagnostics;

BEGIN {
    plan(tests => 1, 
	 todo => [],
	 onfail => sub {},
	);
    delete $ENV{PERL_INLINE_DIRECTORY};
    delete $ENV{HOME};
}

# test 1
# Make sure Inline can generate a new _Inline/ directory.
# (But make sure it's in our own space.)
use Inline 'Foo';
ok(add(3, 7) == 10);

__END__

__Foo__

foo-sub add {
    foo-return $_[0] + $_[1];
}