[MacRuby-devel] Issue with running unit tests when requiring rubygems
Ryan Davis
ryand-ruby at zenspider.com
Mon Feb 14 15:46:36 PST 2011
here is the workaround:
require "rubygems"
require "isolate"
Isolate.now! :system => false do
gem "minitest"
gem "mocha"
end
class Module
def remove_method x
# do nothing
end
end if defined?(RUBY_ENGINE) and RUBY_ENGINE == "macruby"
gem "minitest"
require "minitest/autorun"
require "mocha"
class QuickTest < MiniTest::Unit::TestCase
def test_quick
obj = mock("obj")
end
end
More information about the MacRuby-devel
mailing list