summaryrefslogtreecommitdiff
path: root/tests/run.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tests/run.lua')
-rw-r--r--tests/run.lua23
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/run.lua b/tests/run.lua
index de48f0b..7a245f9 100644
--- a/tests/run.lua
+++ b/tests/run.lua
@@ -4281,6 +4281,29 @@ test("Default label evaluation defines the fallback when absent", function()
truthy(operations[2].options.default)
end)
+test("Explicit color configuration forces its feature link", function()
+ local host = MemoryHost.new({
+ configuration = {
+ mark_cursor_color = "Search",
+ },
+ highlight_groups = {
+ CleverFCursor = { guifg = "blue" },
+ },
+ })
+ local feedback = feedback_service.new(host)
+
+ local results = feedback:evaluate_feature_links()
+ same("configured", results.CleverFCursor.source)
+ same("Search", results.CleverFCursor.target)
+ same("Search", host:highlight_groups().CleverFCursor.link)
+
+ local operations = host:operations()
+ local definition = operations[#operations]
+ same("define_highlight_group", definition.operation)
+ same("CleverFCursor", definition.name)
+ truthy(definition.options.force)
+end)
+
for _, item in ipairs(tests) do
local ok, failure = xpcall(item.body, debug.traceback)
if not ok then