diff options
| author | Jackson Moore <jacksonmoore@tuta.io> | 2026-09-04 11:34:56 +0200 |
|---|---|---|
| committer | Jackson Moore <jacksonmoore@tuta.io> | 2026-09-04 11:34:56 +0200 |
| commit | 0809f1eb0c73648cae15806cf8a43ad35f445f7c (patch) | |
| tree | d6cc1fe0dfc2b8670fbf335d30e3c9d7d5e6cdeb /tests/run.lua | |
| parent | 4df4d9e046d40f32ddb08ebba0cb026e9546178b (diff) | |
Preserve colorscheme default labels
Diffstat (limited to 'tests/run.lua')
| -rw-r--r-- | tests/run.lua | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/tests/run.lua b/tests/run.lua index 082b952..696026e 100644 --- a/tests/run.lua +++ b/tests/run.lua @@ -4233,6 +4233,30 @@ test("Default label fallback covers GUI and terminal rendering", function() truthy(fresh.cterm.bold) end) +test("Default label evaluation preserves a colorscheme definition", function() + local supplied = { + guifg = "blue", + gui = { italic = true }, + } + local host = MemoryHost.new({ + highlight_groups = { + CleverFDefaultLabel = supplied, + }, + }) + local feedback = feedback_service.new(host) + + local result = feedback:ensure_default_label() + same("colorscheme", result.source) + falsy(result.applied) + same("blue", result.definition.guifg) + truthy(result.definition.gui.italic) + same("blue", host:highlight_groups().CleverFDefaultLabel.guifg) + + local operations = host:operations() + same(1, #operations) + same("read_highlight_group", operations[1].operation) +end) + for _, item in ipairs(tests) do local ok, failure = xpcall(item.body, debug.traceback) if not ok then |
