Guest User

Untitled

a guest
May 28th, 2015
276
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.10 KB | None | 0 0
  1. def test_sub_is_like_find_and_replace
  2.   assert_equal __, "one two-three".sub(/(t\w*)/) { $1[0, 1] }
  3. end
Advertisement
Add Comment
Please, Sign In to add comment