@@ -25,8 +25,10 @@ import "core:strings"
25
25
import " core:mem"
26
26
import " core:time"
27
27
28
+ TEST_SUITE_PATH_PNG :: ODIN_ROOT + " tests/core/assets/PNG"
29
+ TEST_SUITE_PATH_BMP :: ODIN_ROOT + " tests/core/assets/BMP"
30
+
28
31
I_Error :: image.Error
29
- TEST_SUITE_PATH :: ODIN_ROOT + " tests/core/assets/"
30
32
31
33
Test :: struct {
32
34
file: string ,
@@ -1452,7 +1454,7 @@ png_test_no_postproc :: proc(t: ^testing.T) {
1452
1454
1453
1455
run_png_suite :: proc (t: ^testing.T, suite: []Test) {
1454
1456
for file in suite {
1455
- test_file := strings.concatenate ({TEST_SUITE_PATH , " /PNG /" , file.file, " .png" }, context .allocator)
1457
+ test_file := strings.concatenate ({TEST_SUITE_PATH_PNG , " /" , file.file, " .png" }, context .allocator)
1456
1458
defer delete (test_file)
1457
1459
1458
1460
img: ^png.Image
@@ -2315,7 +2317,7 @@ bmp_test_known_bad :: proc(t: ^testing.T) {
2315
2317
2316
2318
run_bmp_suite :: proc (t: ^testing.T, suite: []Test) {
2317
2319
for file in suite {
2318
- test_file := strings.concatenate ({TEST_SUITE_PATH , " /BMP /" , file.file, " .bmp" }, context .allocator)
2320
+ test_file := strings.concatenate ({TEST_SUITE_PATH_BMP , " /" , file.file, " .bmp" }, context .allocator)
2319
2321
defer delete (test_file)
2320
2322
2321
2323
for test in file.tests {
@@ -2325,7 +2327,7 @@ run_bmp_suite :: proc(t: ^testing.T, suite: []Test) {
2325
2327
testing.expectf (t, passed, " %q failed to load with error %v." , file.file, err)
2326
2328
2327
2329
if err == nil { // No point in running the other tests if it didn't load.
2328
- qoi_file := strings.concatenate ({TEST_SUITE_PATH , " /BMP /" , file.file, " .qoi" }, context .allocator)
2330
+ qoi_file := strings.concatenate ({TEST_SUITE_PATH_BMP , " /" , file.file, " .qoi" }, context .allocator)
2329
2331
defer delete (qoi_file)
2330
2332
2331
2333
qoi.save (qoi_file, img)
0 commit comments