Skip to content

Commit

Permalink
Fixup #5409: Add missing lexer specs
Browse files Browse the repository at this point in the history
  • Loading branch information
straight-shoota authored and jhass committed Dec 19, 2017
1 parent 993916a commit 449cb77
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion spec/compiler/lexer/lexer_spec.cr
Expand Up @@ -366,7 +366,7 @@ describe "Lexer" do
token.type.should eq(:EOF)
end

assert_syntax_error "/foo", "unterminated regular expression"
assert_syntax_error "/foo", "Unterminated regular expression"
assert_syntax_error ":\"foo", "unterminated quoted symbol"

it "lexes utf-8 char" do
Expand Down
4 changes: 2 additions & 2 deletions spec/compiler/lexer/lexer_string_spec.cr
Expand Up @@ -231,7 +231,7 @@ describe "Lexer string" do
token = lexer.next_token
state = token.delimiter_state

expect_raises Crystal::SyntaxException, /unterminated heredoc/ do
expect_raises Crystal::SyntaxException, "Unterminated heredoc" do
loop do
token = lexer.next_string_token state
break if token.type == :DELIMITER_END
Expand Down Expand Up @@ -282,7 +282,7 @@ describe "Lexer string" do
it "raises on unexpected EOF while lexing heredoc" do
lexer = Lexer.new("<<-aaa")

expect_raises Crystal::SyntaxException, /unexpected EOF on heredoc identifier/ do
expect_raises Crystal::SyntaxException, "Unexpected EOF on heredoc identifier" do
lexer.next_token
end
end
Expand Down

0 comments on commit 449cb77

Please sign in to comment.