aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/test/core_ext/string_ext_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activesupport/test/core_ext/string_ext_test.rb')
-rw-r--r--activesupport/test/core_ext/string_ext_test.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/activesupport/test/core_ext/string_ext_test.rb b/activesupport/test/core_ext/string_ext_test.rb
index c5a000b67a..b1ab9533e7 100644
--- a/activesupport/test/core_ext/string_ext_test.rb
+++ b/activesupport/test/core_ext/string_ext_test.rb
@@ -455,6 +455,8 @@ class StringAccessTest < ActiveSupport::TestCase
test "#to with negative Integer, position is counted from the end" do
assert_equal "hell", "hello".to(-2)
+ assert_equal "h", "hello".to(-5)
+ assert_equal "", "hello".to(-7)
end
test "#from and #to can be combined" do