dimensions
dimensions copied to clipboard
Fix require in tests in Ruby 1.9
Ruby 1.9 doesn’t has .
in $LOAD_PATH
, so we need another way to require test helper to run tests.
Relative requires are hard to write and maintain. The common solution to this problem is to have the test runner (in this case, the rake task) put test/
onto RUBYLIB. This is what RSpec does with spec/
directory by default.
Rake::TestTask.new do |t|
t.libs << 'test'
t.verbose = true
t.warning = true
end