From a890550aeba848f1e07ec71967463ee4b247c623 Mon Sep 17 00:00:00 2001 From: elijah Date: Sat, 9 Apr 2016 23:44:53 -0700 Subject: fix tests --- lib/leap_cli/bootstrap.rb | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'lib/leap_cli') diff --git a/lib/leap_cli/bootstrap.rb b/lib/leap_cli/bootstrap.rb index 5492591..b7bc8e9 100644 --- a/lib/leap_cli/bootstrap.rb +++ b/lib/leap_cli/bootstrap.rb @@ -8,9 +8,12 @@ module LeapCli extend LeapCli::Log extend self - def setup(argv) + # + # the argument leapfile_path is only used for tests + # + def setup(argv, leapfile_path=nil) setup_logging(argv) - setup_leapfile(argv) + setup_leapfile(argv, leapfile_path) end # @@ -83,8 +86,8 @@ module LeapCli # # load the leapfile and set the Path variables. # - def setup_leapfile(argv) - LeapCli.leapfile.load + def setup_leapfile(argv, leapfile_path) + LeapCli.leapfile.load(leapfile_path) if LeapCli.leapfile.valid? Path.set_platform_path(LeapCli.leapfile.platform_directory_path) Path.set_provider_path(LeapCli.leapfile.provider_directory_path) -- cgit v1.2.3