initial: panel-test v0.1.0 — 10 assertions

This commit is contained in:
Calic
2026-06-13 23:09:50 +02:00
commit ebb4d8132f
5 changed files with 219 additions and 0 deletions

33
README.md Normal file
View File

@@ -0,0 +1,33 @@
# lib-core.panel-test
Test-module for `lib-core.panel`. 10 assertions covering registry lifecycle,
theme validation, error handling, pause-gate, and context-menu dispatch.
**Version:** 0.1.0
**Lib-ID:** lib-core.panel-test
**Requires:** lib-core.panel v0.1.0
**Tags:** test, panel, ui
## Running
```bash
export PATH="/c/msys64/mingw64/bin:$PATH"
cd ~/Projects/Sporel/sporel-engine
SPOREL_LIBS_DIR=~/Projects/Sporel/sporel-libs SPOREL_CI=1 SPOREL_LOG_STDERR=1 \
./build/Sporel.exe --test-libs=lib-core.panel-test 2>&1 | tail -15
```
Expected: `pass=10 fail=0`.
## Assertion Summary
1. register + open / close round-trip
2. close after open works
3. toggle twice opens then closes
4. open with unknown widget_id raises an error
5. set_theme with valid override is visible via get_theme
6. set_theme with unknown key raises an error
7. register without render function raises an error
8. pause_on_open=true widget makes is_pausing() true; close makes it false
9. context-menu action callback invoked on click inside its row
10. non-pause widget: is_pausing() is false