diff options
| author | Luke Kanies <luke@madstop.com> | 2009-08-01 23:24:54 -0700 |
|---|---|---|
| committer | James Turnbull <james@lovedthanlost.net> | 2009-08-02 16:38:49 +1000 |
| commit | 54a225dd26d867d5672df48a5bc0ed858821bf40 (patch) | |
| tree | de489ee258993c812ad7cbc803fb9657721b6d1c | |
| parent | 1ce31b4f5c5a38aa6914a5367ea6dd8db53174ab (diff) | |
Fixing tests broken by caching autoload results
These tests tried to load something, verified
the loads didn't work, and then created
the thing to load. This is a bit silly,
so I just removed those sections of the tests.
Signed-off-by: Luke Kanies <luke@madstop.com>
| -rw-r--r-- | lib/puppet/parser/scope.rb | 2 | ||||
| -rwxr-xr-x | test/language/functions.rb | 4 | ||||
| -rwxr-xr-x | test/util/subclass_loader.rb | 7 |
3 files changed, 3 insertions, 10 deletions
diff --git a/lib/puppet/parser/scope.rb b/lib/puppet/parser/scope.rb index 71b9be27c..d6d663041 100644 --- a/lib/puppet/parser/scope.rb +++ b/lib/puppet/parser/scope.rb @@ -403,7 +403,7 @@ class Puppet::Parser::Scope # Undefine a variable; only used for testing. def unsetvar(var) - table = ephemeral?(var) ? @ephemeral : @table + table = ephemeral?(var) ? @ephemeral : @symtable if table.include?(var) table.delete(var) end diff --git a/test/language/functions.rb b/test/language/functions.rb index 9f0e8a594..af0732559 100755 --- a/test/language/functions.rb +++ b/test/language/functions.rb @@ -359,8 +359,8 @@ class TestLangFunctions < Test::Unit::TestCase end def test_autoloading_functions - assert_equal(false, Puppet::Parser::Functions.function(:autofunc), - "Got told autofunc already exists") + #assert_equal(false, Puppet::Parser::Functions.function(:autofunc), + # "Got told autofunc already exists") dir = tempfile() $: << dir diff --git a/test/util/subclass_loader.rb b/test/util/subclass_loader.rb index 34b8803fc..0efd636f4 100755 --- a/test/util/subclass_loader.rb +++ b/test/util/subclass_loader.rb @@ -31,13 +31,6 @@ class TestPuppetUtilSubclassLoader < Test::Unit::TestCase end def test_subclass_loading - # Make sure we don't get a failure but that we also get nothing back - assert_nothing_raised do - assert_nil(LoadTest.faker(:fake), - "Got something back from a missing subclass") - assert_nil(LoadTest.fake, - "Got something back from missing subclass method") - end # Make a fake client mk_subclass("fake", "puppet/fakeloaders", "TestPuppetUtilSubclassLoader::LoadTest") |
