Rakefile in mosquitto-0.2 vs Rakefile in mosquitto-0.3

- old
+ new

@@ -15,28 +15,32 @@ ext.name = 'mosquitto_ext' ext.ext_dir = 'ext/mosquitto' CLEAN.include 'lib/**/mosquitto_ext.*' end -desc 'Run mosquitto tests' -Rake::TestTask.new(:test) do |t| - t.test_files = Dir.glob("test/**/test_*.rb") - t.verbose = true - t.warning = true -end +namespace :test do + desc 'Run mosquitto tests' + Rake::TestTask.new(:unit) do |t| + t.test_files = Dir.glob("test/**/test_*.rb").reject{|t| t =~ /integration/ } + t.verbose = true + t.warning = true + end -desc 'Run mosquitto integration tests' -Rake::TestTask.new(:integration) do |t| - t.test_files = Dir.glob("test/test_integration.rb") - t.verbose = true - t.warning = true + desc 'Run mosquitto integration tests' + Rake::TestTask.new(:integration) do |t| + t.test_files = Dir.glob("test/test_integration.rb") + t.verbose = true + t.warning = true + end end namespace :debug do desc "Run the test suite under gdb" task :gdb do system "gdb --args ruby rake" end end -task :test => :compile +task 'test:unit' => :compile +task 'test:integration' => :compile +task :test => ['test:unit', 'test:integration'] task :default => :test \ No newline at end of file