fix unit tests

This commit is contained in:
Irmen de Jong 2023-06-03 21:39:34 +02:00
parent 9314c346da
commit 1bdae53f4e

View File

@ -46,6 +46,7 @@ private fun compileTheThing(filepath: Path, optimize: Boolean, target: ICompilat
private fun prepareTestFiles(source: String, optimize: Boolean, target: ICompilationTarget): Pair<String, Path> { private fun prepareTestFiles(source: String, optimize: Boolean, target: ICompilationTarget): Pair<String, Path> {
val searchIn = mutableListOf(examplesDir) val searchIn = mutableListOf(examplesDir)
when (target) { when (target) {
is C64Target -> searchIn.add(0, assumeDirectory(examplesDir, "c64"))
is Cx16Target -> searchIn.add(0, assumeDirectory(examplesDir, "cx16")) is Cx16Target -> searchIn.add(0, assumeDirectory(examplesDir, "cx16"))
is VMTarget -> searchIn.add(0, assumeDirectory(examplesDir, "vm")) is VMTarget -> searchIn.add(0, assumeDirectory(examplesDir, "vm"))
is C128Target -> searchIn.add(0, assumeDirectory(examplesDir, "c128")) is C128Target -> searchIn.add(0, assumeDirectory(examplesDir, "c128"))
@ -69,10 +70,13 @@ class TestCompilerOnExamplesC64: FunSpec({
"bdmusic", "bdmusic",
"bdmusic-irq", "bdmusic-irq",
"charset", "charset",
"cube3d",
"cube3d-sprites", "cube3d-sprites",
"plasma", "plasma",
"rasterbars",
"sprites", "sprites",
"starfield", "starfield",
"tehtriz",
"turtle-gfx", "turtle-gfx",
"wizzine", "wizzine",
), ),
@ -94,13 +98,17 @@ class TestCompilerOnExamplesCx16: FunSpec({
val onlyCx16 = cartesianProduct( val onlyCx16 = cartesianProduct(
listOf( listOf(
"vtui/testvtui", "vtui/testvtui",
"pcmaudio/play-adpcm",
"pcmaudio/stream-wav",
"amiga", "amiga",
"bdmusic", "bdmusic",
"bobs", "bobs",
"bubbleuniverse",
"circles", "circles",
"cobramk3-gfx", "cobramk3-gfx",
"colorbars", "colorbars",
"cube3d", "cube3d",
"cxlogo",
"datetime", "datetime",
"diskspeed", "diskspeed",
"fileseek", "fileseek",
@ -139,7 +147,6 @@ class TestCompilerOnExamplesBothC64andCx16: FunSpec({
"cube3d", "cube3d",
"cube3d-float", "cube3d-float",
"cube3d-gfx", "cube3d-gfx",
"cxlogo",
"dirlist", "dirlist",
"fibonacci", "fibonacci",
"line-circle-gfx", "line-circle-gfx",
@ -149,7 +156,6 @@ class TestCompilerOnExamplesBothC64andCx16: FunSpec({
"mandelbrot-gfx", "mandelbrot-gfx",
"numbergame", "numbergame",
"primes", "primes",
"rasterbars",
"screencodes", "screencodes",
"sorting", "sorting",
"swirl", "swirl",