Updated koans from src.

This commit is contained in:
Jim Weirich
2010-09-28 14:17:46 -04:00
parent c0bbe773d9
commit b41d6167b4
11 changed files with 174 additions and 28 deletions

View File

@@ -3,11 +3,11 @@ require File.expand_path(File.dirname(__FILE__) + '/edgecase')
class AboutRegularExpressions < EdgeCase::Koan
def test_a_pattern_is_a_regular_expression
assert_equal Regexp, /pattern/.class
assert_equal __, /pattern/.class
end
def test_a_regexp_can_search_a_string_for_matching_content
assert_equal "match", "some matching content"[/match/]
assert_equal __, "some matching content"[/match/]
end
def test_a_failed_match_returns_nil