-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add another test for windows backslashs
- Loading branch information
Showing
2 changed files
with
25 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
// imports | ||
import "deps/calendar_header.vpr" | ||
// sources | ||
|
||
// derived | ||
|
||
// invariants | ||
|
||
|
||
// interactions | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package lore | ||
import munit.FunSuite | ||
import lore.AST.* | ||
import lore.backends.ViperBackend | ||
|
||
class ViperBackendSuite extends FunSuite: | ||
test("Imports"): | ||
import java.nio.file.{Path} | ||
import java.nio.charset.StandardCharsets | ||
|
||
val compiled = ViperBackend.compileAsSingleFile(List(TViperImport(Path.of("deps/calendar_header.vpr")))) | ||
val expectation = String(getClass.getClassLoader.getResourceAsStream("importstest.viper").readAllBytes, StandardCharsets.UTF_8) | ||
|
||
assertEquals(compiled, expectation) |