Skip to content

Commit

Permalink
Exclamation point, comment, whitespace causes very long parse times …
Browse files Browse the repository at this point in the history
…- add test #41
  • Loading branch information
JasonBarnabe committed Dec 3, 2014
1 parent 872b6c1 commit 746a216
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions test/test_parser.rb
Expand Up @@ -189,5 +189,33 @@ def test_broken_comment
}
assert time.real < 1
end

def test_broken_comment_exclamation
time = Benchmark.measure {
begin
CSSPool.CSS <<-eocss
!
/**/
eocss
rescue
end
}
assert time.real < 1
end

end
end

0 comments on commit 746a216

Please sign in to comment.