mirror of
				https://github.com/fog/fog.git
				synced 2022-11-09 13:51:43 -05:00 
			
		
		
		
	update rake task to run all tests, mocked and unmocked
This commit is contained in:
		
							parent
							
								
									4eb0b8ad22
								
							
						
					
					
						commit
						a16e334224
					
				
					 1 changed files with 12 additions and 19 deletions
				
			
		
							
								
								
									
										31
									
								
								Rakefile
									
										
									
									
									
								
							
							
						
						
									
										31
									
								
								Rakefile
									
										
									
									
									
								
							| 
						 | 
				
			
			@ -45,11 +45,18 @@ end
 | 
			
		|||
 | 
			
		||||
task :default => :test
 | 
			
		||||
 | 
			
		||||
require 'rake/testtask'
 | 
			
		||||
Rake::TestTask.new(:test) do |test|
 | 
			
		||||
  test.libs << 'lib' << 'test'
 | 
			
		||||
  test.pattern = 'test/**/test_*.rb'
 | 
			
		||||
  test.verbose = true
 | 
			
		||||
task :test do
 | 
			
		||||
  sh("export FOG_MOCK=true  && bundle exec spec -cfs spec") &&
 | 
			
		||||
  sh("export FOG_MOCK=true  && bundle exec shindo tests") &&
 | 
			
		||||
  sh("export FOG_MOCK=false && bundle exec spec -cfs spec") &&
 | 
			
		||||
  sh("export FOG_MOCK=false && bundle exec shindo tests")
 | 
			
		||||
end
 | 
			
		||||
 | 
			
		||||
task :ci do
 | 
			
		||||
  sh("export FOG_MOCK=true  && bundle exec spec spec") &&
 | 
			
		||||
  sh("export FOG_MOCK=true  && bundle exec shindont tests") &&
 | 
			
		||||
  sh("export FOG_MOCK=false && bundle exec spec spec") &&
 | 
			
		||||
  sh("export FOG_MOCK=false && bundle exec shindont tests")
 | 
			
		||||
end
 | 
			
		||||
 | 
			
		||||
desc "Generate RCov test coverage and open in your browser"
 | 
			
		||||
| 
						 | 
				
			
			@ -73,20 +80,6 @@ task :console do
 | 
			
		|||
  sh "irb -rubygems -r ./lib/#{name}.rb"
 | 
			
		||||
end
 | 
			
		||||
 | 
			
		||||
#############################################################################
 | 
			
		||||
#
 | 
			
		||||
# Custom tasks (add your own tasks here)
 | 
			
		||||
#
 | 
			
		||||
#############################################################################
 | 
			
		||||
 | 
			
		||||
require 'spec/rake/spectask'
 | 
			
		||||
Spec::Rake::SpecTask.new(:spec) do |spec|
 | 
			
		||||
  spec.libs << 'lib' << 'spec' << File.expand_path("../", __FILE__)
 | 
			
		||||
  spec.spec_opts = ['--colour', "--format", "specdoc"]
 | 
			
		||||
  spec.spec_files = FileList['spec/**/*_spec.rb']
 | 
			
		||||
end
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
#############################################################################
 | 
			
		||||
#
 | 
			
		||||
# Packaging tasks
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue