forked from danielsdeleo/statsd
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Rakefile
41 lines (35 loc) · 983 Bytes
/
Rakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
begin
require 'rubygems'
require 'rubygems/package_task'
spec = eval(File.read("statsd.gemspec"), nil, 'statsd.gemspec')
Gem::PackageTask.new(spec).define
rescue LoadError
desc "You gotta have rubygems to make the gem"
task(:gem) { abort "install rubygems to build this gem"}
end
begin
require 'rspec/core/rake_task'
RSpec::Core::RakeTask.new
rescue LoadError
desc "install rspec to run tests"
task(:spec) { abort "install rspec to run the tests" }
end
task :default => :spec
begin
require 'rcov/rcovtask'
Rcov::RcovTask.new do |spec|
spec.libs << 'lib' << 'spec'
spec.pattern = 'spec/**/*_spec.rb'
spec.verbose = true
end
rescue LoadError
desc "install rcov to generate test coverage reports"
task(:rcov) { abort "install rcov to analyze test coverage"}
end
begin
require 'yard'
YARD::Rake::YardocTask.new
rescue LoadError
desc "install yard to generate documentation"
task(:yard) { abort "install yard to generate docs"}
end