Skip to content

Commit ea32815

Browse files
committed
fix e2e tests
1 parent ef7b2a1 commit ea32815

File tree

2 files changed

+7
-13
lines changed

2 files changed

+7
-13
lines changed

pomsky-bin/tests/e2e.rs

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -327,8 +327,7 @@ fn specify_features() {
327327
"variables,boundaries,dot,atomic-groups,lazy-mode,named-groups",
328328
]);
329329
cmd.assert().failure().stderr(
330-
r#"error P0302(syntax):
331-
× Numbered capturing groups aren't supported
330+
r#"error P0302(syntax): × Numbered capturing groups aren't supported
332331
╭────
333332
1 │ :(.)
334333
· ──┬─
@@ -357,26 +356,23 @@ fn test_output() {
357356
]);
358357
cmd.assert().failure().stderr(
359358
r#"warning: The `--test` argument is deprecated, use the `pomsky test` subcommand instead
360-
error P0501(test):
361-
× The regex did not find this match within the test string
359+
error P0501(test): × The regex did not find this match within the test string
362360
╭─[6:11]
363361
5 │ reject in "fastest";
364362
6 │ match "fanta" in "fantastic"; # wrong
365363
· ───┬───
366364
· ╰── error occurred here
367365
7 │ match "test" as { 1: "" } in "testament";
368366
╰────
369-
error P0505(test):
370-
× The regex match does not have the expected capture group
367+
error P0505(test): × The regex match does not have the expected capture group
371368
╭─[7:23]
372369
6 │ match "fanta" in "fantastic"; # wrong
373370
7 │ match "test" as { 1: "" } in "testament";
374371
· ┬
375372
· ╰── error occurred here
376373
8 │ match "test" as { 1: "?" } in "test!"; # wrong
377374
╰────
378-
error P0503(test):
379-
× The regex found a different match in the test string
375+
error P0503(test): × The regex found a different match in the test string
380376
╭─[8:11]
381377
7 │ match "test" as { 1: "" } in "testament";
382378
8 │ match "test" as { 1: "?" } in "test!"; # wrong
@@ -385,8 +381,7 @@ error P0503(test):
385381
9 │ match "test" as { foo: "!" } in "test!"; # wrong
386382
╰────
387383
help: The actual match is "test!"
388-
error P0503(test):
389-
× The regex found a different match in the test string
384+
error P0503(test): × The regex found a different match in the test string
390385
╭─[9:11]
391386
8 │ match "test" as { 1: "?" } in "test!"; # wrong
392387
9 │ match "test" as { foo: "!" } in "test!"; # wrong
@@ -438,8 +433,7 @@ fn json_output_errors() {
438433
help: vec![],
439434
fixes: vec![],
440435
visual: String::from(
441-
"error P0100(syntax):
442-
× Expected character class, string, code point, Unicode property or `]`
436+
"error P0100(syntax): × Expected character class, string, code point, Unicode property or `]`
443437
╭────
444438
1 │ [.][^test]
445439
· ┬

pomsky-syntax/src/lexer/tokenize.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ macro_rules! consume_chain {
3030
$input:ident, $c:ident;
3131
) => {
3232
{
33-
(($c.len_utf8(), Token::Error))
33+
($c.len_utf8(), Token::Error)
3434
}
3535
}
3636
}

0 commit comments

Comments
 (0)