diff options
| author | Joshua Peek <josh@joshpeek.com> | 2012-07-20 15:06:21 -0500 |
|---|---|---|
| committer | Joshua Peek <josh@joshpeek.com> | 2012-07-20 15:06:21 -0500 |
| commit | 175d4244c2f4848f6e4d50af6c5cd45337490134 (patch) | |
| tree | 48cbbdea0243db9af63ee858dacb494c1fb6d4a9 /test | |
| parent | d063089430491fa6398ecebbe0ef7936634f34ea (diff) | |
Extract single and multi line comment parser
Diffstat (limited to 'test')
| -rw-r--r-- | test/test_tokenizer.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/test_tokenizer.rb b/test/test_tokenizer.rb index e757c7d..bbd4387 100644 --- a/test/test_tokenizer.rb +++ b/test/test_tokenizer.rb @@ -29,9 +29,9 @@ class TestTokenizer < Test::Unit::TestCase end def test_skip_comments - assert_equal %w(foo #), tokenize("foo # Comment") - assert_equal %w(foo # bar), tokenize("foo # Comment\nbar") - assert_equal %w(foo //), tokenize("foo // Comment") + assert_equal %w(foo #), tokenize("foo\n# Comment") + assert_equal %w(foo # bar), tokenize("foo\n# Comment\nbar") + assert_equal %w(foo //), tokenize("foo\n// Comment") assert_equal %w(foo /* */), tokenize("foo /* Comment */") assert_equal %w(foo /* */), tokenize("foo /* \nComment\n */") assert_equal %w(foo <!-- -->), tokenize("foo <!-- Comment -->") |
