feat(camera-test): migrate to test-lib (manifest.lib + run_tests) (Test-Opt Phase 3.3)

Per ADR-0037 Tests-as-Libs Convention. Renamed on Gitea + moved
locally. History preserved.
This commit is contained in:
Axel Meyer
2026-05-16 01:20:38 +02:00
parent 723741e8ba
commit e388a105c7
3 changed files with 15 additions and 12 deletions

View File

@@ -5,7 +5,9 @@
local camera = require("lib-core.camera")
local T = engine.test
function init(ctx)
local M = {}
function M.run_tests(ctx)
-- State setters/getters (3)
camera.set_target(100, 200)
local t = camera.target()
@@ -62,3 +64,5 @@ function init(ctx)
-- Hygiene: reset bounds for any subsequent loads (init-only-lifecycle but defensive)
camera.clear_bounds()
end
return M

10
manifest.lib Normal file
View File

@@ -0,0 +1,10 @@
{
"id": "lib-core.camera-test",
"role": "test",
"version": "0.1.0",
"api_min": "0.1",
"deps": [
{"id": "lib-core.camera", "version": "0.3.0"},
{"id": "lib-core.input", "version": "0.4.0"}
]
}

View File

@@ -1,11 +0,0 @@
{
"id": "lib-core.camera-test",
"version": "0.1.0",
"kind": "test-module",
"api": "^0.1",
"entry_point": "init.lua",
"deps": [
{ "id": "lib-core.camera", "version": "0.3.0" },
{ "id": "lib-core.input", "version": "0.4.0" }
]
}