puppetlabs/puppet — pull request #1039 by kbarber (2012-08-15 12:26:27+00:00)
Title: Fix missing forge stub and directory check due to test change in 3.x branch rollup

This fixes a test error that was being thrown by the
modules/install/nonexistent_directory.rb file.

In recent commits we added a more clever way to stub the forge host in 2.7.x,
and obtain a forge hostname. This test however went from being a non-network
capable test to a networked one in 3.x, so the rollup from 2.7.x->3.x meant our
changes weren't applied to this particular case. This patch fixes that by
adding the correct stubbing method 'stub_forge_on' to the top of the file.

It also corrects a negated directory check which creaped in during merge up and
ensures proper cleanup using the new teardown mechanism (like the other tests).