Skip to content

Commit

Permalink
Add tests
Browse files Browse the repository at this point in the history
  • Loading branch information
veera-sivarajan committed May 19, 2023
1 parent 13e5cd6 commit 8172596
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions boa_parser/src/parser/tests/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -599,3 +599,18 @@ fn hashbang_use_strict_with_with_statement() {
fn hashbang_comment() {
check_script_parser(r"#!Comment Here", vec![], &mut Interner::default());
}

#[test]
fn deny_unicode_escape_in_false_expression() {
check_invalid_script(r"let x = f\u{61}lse;");
}

#[test]
fn deny_unicode_escape_in_true_expression() {
check_invalid_script(r"let x = tru\u{65};");
}

#[test]
fn deny_unicode_escape_in_null_expression() {
check_invalid_script(r"let x = n\u{75}ll;");
}

0 comments on commit 8172596

Please sign in to comment.