Report exposing list end error in imports

This commit is contained in:
Agus Zubiaga 2024-05-06 23:38:12 -03:00
parent dc18597a0e
commit 755e16cb10
No known key found for this signature in database
2 changed files with 41 additions and 2 deletions

View file

@ -5024,6 +5024,26 @@ mod test_reporting {
I just saw the `exposing` keyword, so I was expecting to see `[` next.
"###);
test_report!(
unfinished_import_exposing_name,
indoc!(
r"
import svg.Path exposing [3
"
),
@r###"
WEIRD EXPOSING in tmp/unfinished_import_exposing_name/Test.roc
I'm partway through parsing an exposing list, but I got stuck here:
4 import svg.Path exposing [3
^
I was expecting a type, value, or function name next, like:
import Svg exposing [Path, arc, rx]
"###);
test_report!(
ingested_file_import_ann_syntax_err,
indoc!(