mirror of
https://github.com/erg-lang/erg.git
synced 2025-09-29 04:24:43 +00:00
Test: ensure that multi-line strings are invalid
This commit is contained in:
parent
6619bbee8a
commit
4c65b6e729
2 changed files with 9 additions and 0 deletions
4
compiler/erg_parser/tests/failed_str_lit.er
Normal file
4
compiler/erg_parser/tests/failed_str_lit.er
Normal file
|
@ -0,0 +1,4 @@
|
|||
# compile error
|
||||
a = "
|
||||
hello, world
|
||||
"
|
|
@ -6,6 +6,11 @@ use erg_parser::error::ParserRunnerErrors;
|
|||
use erg_parser::lex::Lexer;
|
||||
use erg_parser::ParserRunner;
|
||||
|
||||
#[test]
|
||||
fn parse_str_literal() -> Result<(), ParserRunnerErrors> {
|
||||
expect_failure("tests/failed_str_lit.er")
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn parse_dependent() -> Result<(), ParserRunnerErrors> {
|
||||
expect_success("tests/dependent.er")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue