aboutsummaryrefslogtreecommitdiff
path: root/tests/scene-loader-test.scm
diff options
context:
space:
mode:
authorGene Pasquet <dev@etenil.net>2026-04-18 05:49:34 +0100
committerGene Pasquet <dev@etenil.net>2026-04-18 05:49:34 +0100
commitc2085be2dd2a0cb3da05991847e35080915e547e (patch)
treee89a0f3c347b3106b15b69b09dcf29f93a7ef627 /tests/scene-loader-test.scm
parent38eee24832fe6da4f135cae455881ab97953b23a (diff)
rename modules
Diffstat (limited to 'tests/scene-loader-test.scm')
-rw-r--r--tests/scene-loader-test.scm26
1 files changed, 13 insertions, 13 deletions
diff --git a/tests/scene-loader-test.scm b/tests/scene-loader-test.scm
index f2ebde0..e86ea42 100644
--- a/tests/scene-loader-test.scm
+++ b/tests/scene-loader-test.scm
@@ -7,7 +7,7 @@
test)
;; Mock tilemap module
-(module downstroke-tilemap *
+(module (downstroke tilemap) *
(import scheme (chicken base) defstruct)
(defstruct tileset tilewidth tileheight spacing tilecount columns image-source image)
(defstruct layer name width height map)
@@ -18,11 +18,11 @@
(define (tile-rect t) #f)
(define (load-tilemap filename) (make-tilemap width: 100 height: 100 tilewidth: 16 tileheight: 16 tileset-source: "" tileset: (make-tileset tilewidth: 16 tileheight: 16 spacing: 0 tilecount: 256 columns: 16 image-source: "" image: #f) layers: '() objects: '()))
(define (load-tileset filename) (make-tileset tilewidth: 16 tileheight: 16 spacing: 0 tilecount: 256 columns: 16 image-source: "" image: #f)))
-(import downstroke-tilemap)
+(import (downstroke tilemap))
;; Load the real entity module (alist-based)
(include "entity.scm")
-(import downstroke-entity)
+(import (downstroke entity))
(import (only (list-utils alist) plist->alist))
@@ -30,28 +30,28 @@
(define (entity . kws) (plist->alist kws))
;; Mock world module
-(module downstroke-world *
+(module (downstroke world) *
(import scheme (chicken base) defstruct)
(defstruct camera x y)
(defstruct scene entities tilemap tileset camera tileset-texture camera-target background engine-update)
(define (scene-add-entity scene entity)
(update-scene scene
entities: (append (scene-entities scene) (list entity)))))
-(import downstroke-world)
+(import (downstroke world))
;; Mock assets module
-(module downstroke-assets *
+(module (downstroke assets) *
(import scheme (chicken base))
(define (asset-set! assets key value) #f))
-(import downstroke-assets)
+(import (downstroke assets))
;; Mock engine module
-(module downstroke-engine *
+(module (downstroke engine) *
(import scheme (chicken base))
(define (game-renderer game) #f)
(define (game-asset-set! game key value) #f)
(define (game-scene-set! game scene) #f))
-(import downstroke-engine)
+(import (downstroke engine))
;; Mock sdl2
(module sdl2 *
@@ -65,19 +65,19 @@
(define (open-font filename size) (list 'font filename size)))
(import (prefix sdl2-ttf "ttf:"))
-;; Mock downstroke-prefabs
+;; Mock (downstroke prefabs)
;; The mock registry is just an alist ((type . constructor) ...) for test simplicity.
;; instantiate-prefab maps to the constructor call.
-(module downstroke-prefabs *
+(module (downstroke prefabs) *
(import scheme (chicken base))
(define (instantiate-prefab registry type x y w h)
(let ((entry (assq type registry)))
(and entry ((cdr entry) x y w h)))))
-(import downstroke-prefabs)
+(import (downstroke prefabs))
;; Load scene-loader module
(include "scene-loader.scm")
-(import downstroke-scene-loader)
+(import (downstroke scene-loader))
(test-begin "scene-loader")