lib/assert_same.rb in assert_same-0.6.1 vs lib/assert_same.rb in assert_same-0.7.0

- old
+ new

@@ -56,10 +56,16 @@ raise message end end -module Test::Unit::Assertions +test_unit_module = if RUBY_VERSION >= "1.9.0" + Object.const_get('MiniTest').const_get('Assertions') +else + Object.const_get('Test').const_get('Unit').const_get('Assertions') +end + +test_unit_module.module_eval do #Hash[filename][line_number] = offset #For each line in the original file we store its offset (+N or -N lines) #relative to the actual file @@file_offsets = Hash.new { |hash, key| hash[key] = {} }