Skip to content

Commit

Permalink
Munge libdir to autoload module plugins without pluginsync
Browse files Browse the repository at this point in the history
  • Loading branch information
rodjek committed Nov 1, 2011
1 parent dd259e6 commit 7f7e74f
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/rspec-puppet/example/function_example_group.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ module FunctionExampleGroup
def subject
function_name = self.class.top_level_description.downcase

Puppet[:modulepath] = self.respond_to?(:module_path) ? module_path : RSpec.configuration.module_path
Puppet[:libdir] = Dir["#{Puppet[:modulepath]}/*/lib"].entries.join(':')
Puppet::Parser::Functions.autoloader.loadall

scope = Puppet::Parser::Scope.new
Expand Down

0 comments on commit 7f7e74f

Please sign in to comment.