cycle test coverage

This commit is contained in:
Tobias Lütke
2009-06-15 08:55:50 -04:00
parent 68433a52a3
commit 8ac4d6a92a
3 changed files with 10 additions and 2 deletions
+6 -1
View File
@@ -11,10 +11,15 @@ class RegexpTest < Test::Unit::TestCase
assert_equal ['"arg 1"'], '"arg 1"'.scan(QuotedFragment)
end
def test_words
assert_equal ['arg1', 'arg2'], 'arg1 arg2'.scan(QuotedFragment)
end
def test_tags
assert_equal ['<tr>', '</tr>'], '<tr> </tr>'.scan(QuotedFragment)
assert_equal ['<tr></tr>'], '<tr></tr>'.scan(QuotedFragment)
assert_equal ['<style', 'class="hello">', '</style>'], %|<style class="hello">' </style>|.scan(QuotedFragment)
end
def test_quoted_words
assert_equal ['arg1', 'arg2', '"arg 3"'], 'arg1 arg2 "arg 3"'.scan(QuotedFragment)