summaryrefslogtreecommitdiffstats
path: root/t
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2010-09-22 13:10:00 -0500
committerJesse Luehrs <doy@tozt.net>2010-09-22 13:10:00 -0500
commit764032903d595e45c8f792bac361c1c97a36a382 (patch)
treef1037b7f50d89d7479a1c9387677aef17a0c2e01 /t
parent5d3589c862fc8593a95ac572b8eb20e97a593a0c (diff)
downloadpackage-stash-764032903d595e45c8f792bac361c1c97a36a382.tar.gz
package-stash-764032903d595e45c8f792bac361c1c97a36a382.zip
remove bad coderef tests (not how we want to handle vivification)
Diffstat (limited to 't')
-rw-r--r--t/04-get.t41
1 files changed, 0 insertions, 41 deletions
diff --git a/t/04-get.t b/t/04-get.t
index 3176ed1..8499938 100644
--- a/t/04-get.t
+++ b/t/04-get.t
@@ -100,47 +100,6 @@ use Package::Stash;
}
}
-TODO: {
- # making TODO tests at a mixture of BEGIN and runtime is irritating
- my $_TODO;
- BEGIN { $_TODO = "obviously I don't understand this well enough"; }
- BEGIN { $TODO = $_TODO; }
- $TODO = $_TODO;
- BEGIN {
- my $stash = Package::Stash->new('Code');
- my $val = $stash->get_package_symbol('&foo');
- is($val, undef, "got nothing yet");
- }
- {
- no warnings 'void', 'once';
- \&Code::foo;
- }
- BEGIN {
- my $stash = Package::Stash->new('Code');
- my $val = $stash->get_package_symbol('&foo');
- undef $TODO;
- is(ref($val), 'CODE', "got something");
- $TODO = $_TODO;
- SKIP: {
- eval "require PadWalker"
- or skip "needs PadWalker", 1;
- # avoid padwalker segfault
- if (!defined($val)) {
- fail("got the right variable");
- }
- else {
- PadWalker::set_closed_over($val, {'$x' => 1});
- is_deeply({PadWalker::closed_over($stash->get_package_symbol('&foo'))}, {'$x' => 1},
- "got the right variable");
- is_deeply({PadWalker::closed_over(\&Code::foo)}, {'$x' => 1},
- "stash has the right variable");
- }
- }
- }
- BEGIN { undef $TODO; }
- undef $TODO;
-}
-
{
my $stash = Package::Stash->new('Hash::Vivify');
my $val = $stash->get_or_add_package_symbol('%foo');