diff options
author | Lamont Granquist <lamont@scriptkiddie.org> | 2014-11-13 13:06:39 -0800 |
---|---|---|
committer | Lamont Granquist <lamont@scriptkiddie.org> | 2014-11-13 13:06:39 -0800 |
commit | 4be0cce9900dbfb37487b05171b7137331664e1b (patch) | |
tree | 864fd45dc77306f00d9e0cdc28c3fa1d34170904 /spec | |
parent | d80796160625016889ded0ce42fec3ea9945e39e (diff) | |
parent | 62bba23153e7ce5ac04ff1d2a626c9a9d33749ea (diff) | |
download | chef-4be0cce9900dbfb37487b05171b7137331664e1b.tar.gz |
Merge pull request #2418 from opscode/lcg/goalie-merging
Lcg/goalie merging
Diffstat (limited to 'spec')
-rw-r--r-- | spec/unit/application/solo_spec.rb | 2 | ||||
-rw-r--r-- | spec/unit/provider/package/rubygems_spec.rb | 12 |
2 files changed, 8 insertions, 6 deletions
diff --git a/spec/unit/application/solo_spec.rb b/spec/unit/application/solo_spec.rb index 26d7d34caa..80f0bead8b 100644 --- a/spec/unit/application/solo_spec.rb +++ b/spec/unit/application/solo_spec.rb @@ -94,6 +94,7 @@ Enable chef-client interval runs by setting `:client_fork = true` in your config before do Chef::Config[:cookbook_path] = "#{Dir.tmpdir}/chef-solo/cookbooks" Chef::Config[:recipe_url] = "http://junglist.gen.nz/recipes.tgz" + allow(FileUtils).to receive(:rm_rf).and_return(true) allow(FileUtils).to receive(:mkdir_p).and_return(true) @tarfile = StringIO.new("remote_tarball_content") allow(@app).to receive(:open).with("http://junglist.gen.nz/recipes.tgz").and_yield(@tarfile) @@ -135,6 +136,7 @@ Enable chef-client interval runs by setting `:client_fork = true` in your config Chef::Config[:json_attribs] = json_source Chef::Config[:recipe_url] = "http://icanhas.cheezburger.com/lolcats" Chef::Config[:cookbook_path] = "#{Dir.tmpdir}/chef-solo/cookbooks" + allow(FileUtils).to receive(:rm_rf).and_return(true) allow(FileUtils).to receive(:mkdir_p).and_return(true) allow(Chef::Mixin::Command).to receive(:run_command).and_return(true) end diff --git a/spec/unit/provider/package/rubygems_spec.rb b/spec/unit/provider/package/rubygems_spec.rb index db1c21090d..a3a4772229 100644 --- a/spec/unit/provider/package/rubygems_spec.rb +++ b/spec/unit/provider/package/rubygems_spec.rb @@ -90,7 +90,7 @@ describe Chef::Provider::Package::Rubygems::CurrentGemEnvironment do dep = Gem::Dependency.new('rspec', '>= 0') dep_installer = Gem::DependencyInstaller.new allow(@gem_env).to receive(:dependency_installer).and_return(dep_installer) - latest = [[gemspec("rspec", Gem::Version.new("1.3.0")), "http://rubygems.org/"]] + latest = [[gemspec("rspec", Gem::Version.new("1.3.0")), "https://rubygems.org/"]] expect(dep_installer).to receive(:find_gems_with_sources).with(dep).and_return(latest) expect(@gem_env.candidate_version_from_remote(Gem::Dependency.new('rspec', '>= 0'))).to eq(Gem::Version.new('1.3.0')) end @@ -156,7 +156,7 @@ describe Chef::Provider::Package::Rubygems::CurrentGemEnvironment do it "finds a matching gem from a specific gemserver when explicit sources are given" do dep = Gem::Dependency.new('rspec', '>= 0') - latest = [[gemspec("rspec", Gem::Version.new("1.3.0")), "http://rubygems.org/"]] + latest = [[gemspec("rspec", Gem::Version.new("1.3.0")), "https://rubygems.org/"]] expect(@gem_env).to receive(:with_gem_sources).with('http://gems.example.com').and_yield dep_installer = Gem::DependencyInstaller.new @@ -291,9 +291,9 @@ RubyGems Environment: - "install" => "--env-shebang" - "update" => "--env-shebang" - "gem" => "--no-rdoc --no-ri" - - :sources => ["http://rubygems.org/", "http://gems.github.com/"] + - :sources => ["https://rubygems.org/", "http://gems.github.com/"] - REMOTE SOURCES: - - http://rubygems.org/ + - https://rubygems.org/ - http://gems.github.com/ JRUBY_GEM_ENV expect(@gem_env).to receive(:shell_out!).with('/usr/weird/bin/gem env').and_return(double('jruby_gem_env', :stdout => gem_env_out)) @@ -332,10 +332,10 @@ RubyGems Environment: - :benchmark => false - :backtrace => false - :bulk_threshold => 1000 - - :sources => ["http://rubygems.org/", "http://gems.github.com/"] + - :sources => ["https://rubygems.org/", "http://gems.github.com/"] - "gem" => "--no-rdoc --no-ri" - REMOTE SOURCES: - - http://rubygems.org/ + - https://rubygems.org/ - http://gems.github.com/ RBX_GEM_ENV expect(@gem_env).to receive(:shell_out!).with('/usr/weird/bin/gem env').and_return(double('rbx_gem_env', :stdout => gem_env_out)) |