public
Description: Automated jQuery tests with QUnit
Homepage:
Clone URL: git://github.com/jodosha/hanoi.git
hanoi / Rakefile
100644 30 lines (24 sloc) 0.802 kb
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
$:.unshift 'lib'
require 'rubygems'
require 'rake'
require 'rake/testtask'
require 'rake/rdoctask'
require 'spec/rake/spectask'
 
HANOI_VERSION = "0.0.1"
 
task :default => :spec
 
desc 'Build and install the gem (useful for development purposes).'
task :install do
  system "gem build hanoi.gemspec"
  system "sudo gem uninstall hanoi"
  system "sudo gem install --local --no-rdoc --no-ri hanoi-#{HANOI_VERSION}.gem"
  system "rm hanoi-*.gem"
end
 
Spec::Rake::SpecTask.new do |t|
  t.spec_files = FileList['spec/**/*_spec.rb']
  t.spec_opts = %w(-fs --color)
end
 
desc 'Show the file list for the gemspec file'
task :files do
  puts "Files:\n #{Dir['**/*'].reject {|f| File.directory?(f)}.sort.inspect}"
  puts "Test files:\n #{Dir['spec/**/*_spec.rb'].reject {|f| File.directory?(f)}.sort.inspect}"
end