forked from theforeman/smart-proxy
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathRakefile
38 lines (34 loc) · 957 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
require 'rake'
require 'rake/testtask'
require 'rdoc/task'
load 'tasks/proxy_tasks.rake'
load 'tasks/jenkins.rake'
load 'tasks/pkg.rake'
# Test for 1.9
if (RUBY_VERSION.split('.').map{|s|s.to_i} <=> [1,9,0]) > 0 then
PLATFORM = RUBY_PLATFORM
end
desc 'Default: run unit tests.'
task :default => :test
desc 'Test the Foreman Proxy plugin.'
Rake::TestTask.new(:test) do |t|
t.libs << '.'
t.libs << 'lib'
t.libs << 'test'
files = FileList['test/**/*_test.rb']
if PLATFORM =~ /mingw/
files = FileList['test/**/server_ms_test*']
else
files = FileList['test/**/*_test.rb'].delete_if{|f| f =~ /_ms_/}
end
t.test_files = files
t.verbose = true
end
desc 'Generate documentation for the Foreman Proxy plugin.'
Rake::RDocTask.new(:rdoc) do |rdoc|
rdoc.rdoc_dir = 'rdoc'
rdoc.title = 'Proxy'
rdoc.options << '--line-numbers' << '--inline-source'
rdoc.rdoc_files.include('README')
rdoc.rdoc_files.include('lib/**/*.rb')
end