Skip to content

Commit

Permalink
Rakefile for ZenTest.
Browse files Browse the repository at this point in the history
unit_diff and zentest need to be moved into bin for package target to work.

[git-p4: depot-paths = "//src/ZenTest/dev/": change = 2316]
  • Loading branch information
drbrain committed Feb 7, 2006
1 parent 0571ae6 commit 86a854f
Showing 1 changed file with 58 additions and 0 deletions.
58 changes: 58 additions & 0 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
require 'rake'
require 'rake/testtask'
require 'rake/rdoctask'
require 'rake/gempackagetask'

require 'ZenTest'

$VERBOSE = nil

spec = Gem::Specification.new do |s|
s.name = 'ZenTest'
s.version = ZenTest::VERSION
s.summary = ''
s.authors = ['Ryan Davis', 'Eric Hodel']
s.email = 'ryand-ruby@zenspider.com'

s.files = File.read('Manifest.txt').split($/)
s.require_path = 'lib'
s.executables = %w[zentest unit_diff autotest]
end

desc 'Run tests'
task :default => :test

desc 'Run tests'
task :test => [ :test_new, :test_old ]

desc 'The new tests' # TODO make me just test
Rake::TestTask.new :test_new do |t|
t.libs << 'test'
t.verbose = true
end

desc 'The old tests' # TODO remove me
task :test_old do
sh "ruby -I. ./TestZenTest.rb #{ENV['TEST']}"
end

desc 'Update Manifest.txt'
task :update_manifest do
sh "p4 open Manifest.txt; find . -type f | sed -e 's%./%%' | egrep -v 'swp|~' | egrep -v '^(doc|pkg)/' | sort > Manifest.txt"
end

desc 'Generate RDoc'
Rake::RDocTask.new :rdoc do |rd|
rd.rdoc_dir = 'doc'
rd.rdoc_files.add 'lib', 'README.txt', 'History.txt',
'LinuxJournalArticle.txt'
rd.main = 'README.txt'
rd.options << '-d' if `which dot` =~ /\/dot/
end

desc 'Build Gem'
Rake::GemPackageTask.new spec do end # WTF? A block is required?

desc 'Clean up'
task :clean => [ :clobber_rdoc, :clobber_package ]

0 comments on commit 86a854f

Please sign in to comment.