Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added test:todo for known broken things.

  • Loading branch information...
commit bdaf1704fb2cd1a4e0e593e5e3447313fb44bdb5 1 parent cc83591
John Barnette authored
Showing with 20 additions and 2 deletions.
  1. +13 −2 Rakefile
  2. +7 −0 todo/example_test.rb
15 Rakefile
View
@@ -29,8 +29,17 @@ Hoe.new("johnson", Johnson::VERSION) do |p|
p.spec_extras = { :extensions => ["ext/spidermonkey/extconf.rb"] }
end
+namespace :test do
+ Rake::TestTask.new("todo") do |t|
+ t.test_files = FileList['todo/**/*_test.rb']
+ t.verbose = true
+ end
+end
+
# make sure the C bits are up-to-date when testing
Rake::Task[:test].prerequisites << :extensions
+Rake::Task["test:todo"].prerequisites << :extensions
+
Rake::Task[:check_manifest].prerequisites << GENERATED_NODE
task :build => :extensions
@@ -41,20 +50,22 @@ Rake::Task[:gem].prerequisites << :extensions
desc "Our johnson requires extensions."
task :extensions => ["lib/johnson/spidermonkey.#{kind}"]
-task :spidermonkey => :submodules do
+task :spidermonkey => "vendor/spidermonkey/jsapi.h" do
if ENV['CROSS']
Dir.chdir("vendor/spidermonkey") { sh "make -f Makefile.ref OS_CONFIG=#{ENV['CROSS']}" }
else
Dir.chdir("vendor/spidermonkey") { sh "make -f Makefile.ref" }
end
end
+
task :spidermonkey => "vendor/spidermonkey/config/#{ENV['CROSS']}.mk" if ENV['CROSS']
file "vendor/spidermonkey/config/MINGW32.mk" => "MINGW32.mk" do |t|
cp t.prerequisites.first, t.name
end
-task :submodules do
+file "vendor/spidermonkey/jsapi.h" do
+ # if this file's missing, pull in the submodule
sh "git submodule init && git submodule update"
end
7 todo/example_test.rb
View
@@ -0,0 +1,7 @@
+require File.expand_path(File.join(File.dirname(__FILE__), "/../test/helper"))
+
+class ParserTest < Test::Unit::TestCase
+ def test_nothing
+ assert false
+ end
+end
Please sign in to comment.
Something went wrong with that request. Please try again.