aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--test/ruby/test_backtrace.rb17
2 files changed, 8 insertions, 14 deletions
diff --git a/ChangeLog b/ChangeLog
index 3b4818d434..2a0317f6a5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Mon Jun 4 12:01:21 2012 Koichi Sasada <ko1@atdot.net>
+
+ * test/ruby/test_backtrace.rb: fix test.
+ Windows path includes `:' character.
+
Mon Jun 4 11:42:39 2012 Koichi Sasada <ko1@atdot.net>
* vm_core.h (rb_location_t): fix type and field name.
diff --git a/test/ruby/test_backtrace.rb b/test/ruby/test_backtrace.rb
index e603c8ad4d..11edd7644f 100644
--- a/test/ruby/test_backtrace.rb
+++ b/test/ruby/test_backtrace.rb
@@ -86,20 +86,9 @@ class TestBacktrace < Test::Unit::TestCase
end
def test_caller_locations
- locs = caller_locations(0); cs = caller(0).map{|line|
- path, lineno, label_str = line.split(':')
- unless label_str
- label_str = lineno
- lineno = 0
- end
- lineno = lineno.to_i
- if /in `(.+?)\'/ =~ label_str
- label = $1
- else
- label = nil
- end
- [path, lineno, label]
+ cs = caller(0); locs = caller_locations(0).map{|loc|
+ loc.to_s
}
- assert_equal(locs.map{|loc| [loc.path, loc.lineno, loc.label]}, cs)
+ assert_equal(cs, locs)
end
end