summaryrefslogtreecommitdiffstats
path: root/t
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2011-01-05 23:05:37 -0600
committerJesse Luehrs <doy@tozt.net>2011-01-05 23:05:37 -0600
commit57011a68cc3bc9ed5443e3089fe73d46fa38a779 (patch)
tree00c1fb5b7bdbbc5bc79f1c3c89cdd855d3f1f1dc /t
parentfbef4983066edbde84d915b4968e65b0efb59534 (diff)
downloadpackage-stash-xs-57011a68cc3bc9ed5443e3089fe73d46fa38a779.tar.gz
package-stash-xs-57011a68cc3bc9ed5443e3089fe73d46fa38a779.zip
fix another edge case with initial values
Diffstat (limited to 't')
-rwxr-xr-xt/07-edge-cases.t2
-rw-r--r--t/lib/CompileTime.pm15
2 files changed, 17 insertions, 0 deletions
diff --git a/t/07-edge-cases.t b/t/07-edge-cases.t
index 02e281b..4f61ca2 100755
--- a/t/07-edge-cases.t
+++ b/t/07-edge-cases.t
@@ -64,4 +64,6 @@ is(exception { $Bar->add_symbol('$foo', \$foo) }, undef,
is(exception { $Bar->add_symbol('$bar', \$bar) }, undef,
"can add PVNV values");
+use_ok('CompileTime');
+
done_testing;
diff --git a/t/lib/CompileTime.pm b/t/lib/CompileTime.pm
new file mode 100644
index 0000000..925bc18
--- /dev/null
+++ b/t/lib/CompileTime.pm
@@ -0,0 +1,15 @@
+package CompileTime;
+use strict;
+use warnings;
+
+use Package::Stash;
+
+our $foo = 23;
+
+BEGIN {
+ my $stash = Package::Stash->new(__PACKAGE__);
+ $stash->add_symbol('$bar', $foo);
+ $stash->add_symbol('$baz', $stash->get_symbol('$foo'));
+}
+
+1;