-
Notifications
You must be signed in to change notification settings - Fork 3
/
Rakefile
36 lines (32 loc) · 934 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
require 'rubygems'
require 'rake'
require 'rake/testtask'
require 'rake/rdoctask'
desc 'Default: run all tests.'
task :default => :test
desc "Test has_phone_numbers."
Rake::TestTask.new(:test) do |t|
t.libs << 'lib'
t.test_files = Dir['test/**/*_test.rb']
t.verbose = true
end
begin
require 'rcov/rcovtask'
namespace :test do
desc "Test has_phone_numbers with Rcov."
Rcov::RcovTask.new(:rcov) do |t|
t.libs << 'lib'
t.test_files = Dir['test/**/*_test.rb']
t.rcov_opts << '--exclude="^(?!lib/|app/)"'
t.verbose = true
end
end
rescue LoadError
end
desc "Generate documentation for has_phone_numbers."
Rake::RDocTask.new(:rdoc) do |rdoc|
rdoc.rdoc_dir = 'rdoc'
rdoc.title = 'has_phone_numbers'
rdoc.options << '--line-numbers' << '--inline-source' << '--main=README.rdoc'
rdoc.rdoc_files.include('README.rdoc', 'CHANGELOG.rdoc', 'LICENSE', 'lib/**/*.rb', 'app/**/*.rb')
end