diff --git a/test/Parsing/Negative.hs b/test/Parsing/Negative.hs index fde6086e4b..635a42b44c 100644 --- a/test/Parsing/Negative.hs +++ b/test/Parsing/Negative.hs @@ -107,6 +107,13 @@ filesErrorTests = $ \case ErrWrongTopModuleName {} -> Nothing _ -> wrongError, + negTest + "Incorrect top module path (markdown)" + $(mkRelDir "issue2674") + $(mkRelFile "Main.juvix.md") + $ \case + ErrWrongTopModuleName {} -> Nothing + _ -> wrongError, negTestAbsDir "Incorrect top module path of an orphan file." (relToProject $(mkRelDir "tests/WithoutPackageFile")) diff --git a/tests/positive/issue2674/Main.juvix.md b/tests/positive/issue2674/Main.juvix.md new file mode 100644 index 0000000000..aea69d3474 --- /dev/null +++ b/tests/positive/issue2674/Main.juvix.md @@ -0,0 +1,3 @@ +```juvix +module X; +``` diff --git a/tests/positive/issue2674/Package.juvix b/tests/positive/issue2674/Package.juvix new file mode 100644 index 0000000000..743e67fdfc --- /dev/null +++ b/tests/positive/issue2674/Package.juvix @@ -0,0 +1,8 @@ +module Package; + +import PackageDescription.V2 open; + +package : Package := + defaultPackage@{ + name := "issue2674"; + };