Skip to content
Newer
Older
100644 48 lines (42 sloc) 1019 Bytes
ade5068 @karmi Initial commit; empty Bundler gem
authored
1 require 'bundler'
2 Bundler::GemHelper.install_tasks
6a92423 @karmi Cleanup .gemspec; Add License and Readme; Add Rake tasks
authored
3
4 task :default => :test
5
6 require 'rake/testtask'
7 Rake::TestTask.new(:test) do |test|
8 test.libs << 'lib' << 'test'
9 test.pattern = 'test/**/*_test.rb'
10 test.verbose = true
11 end
12
4be93d1 @karmi Moved all tests to test/unit and added Rake task accordingly
authored
13 namespace :test do
14 Rake::TestTask.new(:unit) do |test|
15 test.libs << 'lib' << 'test'
16 test.pattern = 'test/unit/*_test.rb'
17 test.verbose = true
18 end
19 end
20
44213de @karmi Added RCov tasks and scented RDoc with SDoc
authored
21 # Generate documentation
22 begin
23 require 'sdoc'
24 rescue LoadError
25 end
6a92423 @karmi Cleanup .gemspec; Add License and Readme; Add Rake tasks
authored
26 require 'rake/rdoctask'
27 Rake::RDocTask.new do |rdoc|
28 rdoc.rdoc_dir = 'rdoc'
29 rdoc.title = "Slingshot"
30 rdoc.rdoc_files.include('README.rdoc')
31 rdoc.rdoc_files.include('lib/**/*.rb')
32 end
44213de @karmi Added RCov tasks and scented RDoc with SDoc
authored
33
34 # Generate coverage reports
35 begin
36 require 'rcov/rcovtask'
37 Rcov::RcovTask.new do |test|
38 test.libs << 'test'
39 test.rcov_opts = ['--exclude', 'gems/*']
40 test.pattern = 'test/**/*_test.rb'
41 test.verbose = true
42 end
43 rescue LoadError
44 task :rcov do
45 abort "RCov is not available. In order to run rcov, you must: sudo gem install rcov"
46 end
47 end
Something went wrong with that request. Please try again.