forked from minad/olelo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathRakefile
51 lines (44 loc) · 1.21 KB
/
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
41
42
43
44
45
46
47
48
49
50
51
require 'rubygems'
require 'rake'
require 'rake/testtask'
require 'rake/rdoctask'
require 'rcov/rcovtask'
task :default => ['test:unit','test:spec','test:coverage']
namespace :test do
Rake::TestTask.new(:unit) do |t|
t.libs << 'test'
t.warning = true
t.test_files = FileList['test/test_*.rb']
end
Rcov::RcovTask.new(:coverage) do |t|
t.rcov_opts << '--exclude' << '/gems/,/ruby-git\/lib/'
t.libs << 'test'
t.warning = false
t.verbose = true
t.test_files = FileList['test/test_*.rb','test/spec_*.rb']
end
Rake::TestTask.new(:spec) do |t|
t.libs << 'test'
t.warning = false # Sinatra warnings
t.test_files = FileList['test/spec_*.rb']
end
end
desc 'Cleanup'
task :clean do |t|
FileUtils.rm_rf 'doc'
FileUtils.rm_rf 'coverage'
FileUtils.rm_rf '.wiki/cache'
FileUtils.rm_rf '.wiki/log'
end
desc 'Remove wiki folder'
task 'clean:all' => :clean do |t|
FileUtils.rm_rf '.wiki'
end
desc 'Generate AkaPortal documentation'
Rake::RDocTask.new(:doc) { |rdoc|
rdoc.rdoc_dir = 'doc'
rdoc.title = 'Git-Wiki Documentation'
rdoc.options << '--line-numbers' << '--inline-source' << '--diagram'
rdoc.options << '--charset' << 'utf-8'
rdoc.rdoc_files.include('**/*.rb')
}