feat(input-test): migrate to test-lib (manifest.lib + run_tests) (Test-Opt Phase 3.2)
Per ADR-0037 Tests-as-Libs Convention. Renamed on Gitea + moved locally. History preserved.
This commit is contained in:
6
init.lua
6
init.lua
@@ -4,7 +4,9 @@
|
|||||||
|
|
||||||
local input = require("lib-core.input")
|
local input = require("lib-core.input")
|
||||||
|
|
||||||
function init(ctx)
|
local M = {}
|
||||||
|
|
||||||
|
function M.run_tests(ctx)
|
||||||
-- Engine surface present (7 assertions)
|
-- Engine surface present (7 assertions)
|
||||||
engine.test.assert(type(engine.input.MOUSE_LEFT) == "number",
|
engine.test.assert(type(engine.input.MOUSE_LEFT) == "number",
|
||||||
"MOUSE_LEFT constant is integer")
|
"MOUSE_LEFT constant is integer")
|
||||||
@@ -52,3 +54,5 @@ function init(ctx)
|
|||||||
engine.test.equals(input.action_count(), 3,
|
engine.test.equals(input.action_count(), 3,
|
||||||
"key-only bind still works after BIND_MAP refactor")
|
"key-only bind still works after BIND_MAP refactor")
|
||||||
end
|
end
|
||||||
|
|
||||||
|
return M
|
||||||
|
|||||||
@@ -1,10 +1,9 @@
|
|||||||
{
|
{
|
||||||
"id": "lib-core.input-test",
|
"id": "lib-core.input-test",
|
||||||
"kind": "test-module",
|
"role": "test",
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"api": "^0.1",
|
"api_min": "0.1",
|
||||||
"entry_point": "init.lua",
|
|
||||||
"deps": [
|
"deps": [
|
||||||
{"id": "lib-core.input", "version": "0.4.0"}
|
{"id": "lib-core.input", "version": "0.4.0"}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user