Geminstaller C0 Coverage Information - RCov

spec/functional/fixtures_spec.rb

Name Total Lines Lines of Code Total Coverage Code Coverage
spec/functional/fixtures_spec.rb 36 24
83.33%
79.17%

Key

Code reported as executed by Ruby looks like this...and this: this line is also marked as covered.Lines considered as run by rcov, but not reported by Ruby, look like this,and this: these lines were inferred by rcov (using simple heuristics).Finally, here's a line marked as not executed.

Coverage Details

1 dir = File.dirname(__FILE__)
2 require File.expand_path("#{dir}/../helper/spec_helper")
3 
4 describe "The sample gem fixtures install and uninstall methods" do
5   it "should be consistent" do
6     GemInstaller::TestGemHome.use
7     @registry = GemInstaller::create_registry
8     @gem_command_manager = @registry.gem_command_manager
9     @gem_spec_manager = @registry.gem_spec_manager
10 
11     # install all the sample gems
12     GemInstaller.install(["--silent", "--config=#{dir}/live_geminstaller_config_all_sample_gems.yml"])
13 
14     # uninstall all the sample gems
15     GemInstaller::TestGemHome.uninstall_all_test_gems
16     
17     all_local_gems = @gem_spec_manager.all_local_gems
18 
19     if GemInstaller::RubyGemsVersionChecker.matches?('>=0.9.5')
20       # no gems should be left
21       test_gems.each do |gem|
22         # We must check each sample gem specifically, because on OSX Leopard, user gems end up 
23         # being found as well, not just the sample gems in the test gem home.
24         @gem_spec_manager.should_not be_is_gem_installed(gem)
25       end
26     else
27       # nothing but sources gem should be left
28       all_local_gems.size.should == 1
29       all_local_gems[0].name.should == 'sources'
30     end
31   end
32 
33   after(:each) do
34     GemInstaller::TestGemHome.uninstall_all_test_gems
35   end
36 end

Generated on Mon May 10 23:40:29 -0700 2010 with rcov 0.9.8