mirror of
https://github.com/centau/vide.git
synced 2026-10-21 11:44:07 +00:00
Fix actions not running in priority order
This commit is contained in:
parent
a4151bd41e
commit
1970d150e0
2 changed files with 30 additions and 4 deletions
|
|
@ -2330,6 +2330,20 @@ TEST("actions", function()
|
|||
|
||||
CHECK(testkit.seq(queue, { 1, 2 }))
|
||||
end
|
||||
|
||||
do CASE "non-consecutive priorities"
|
||||
local queue = {}
|
||||
|
||||
create "Frame" {
|
||||
action(function() table.insert(queue, 100) end, 100),
|
||||
action(function() table.insert(queue, 2.5) end, 2.5),
|
||||
action(function() table.insert(queue, -1) end, -1),
|
||||
action(function() table.insert(queue, 0) end, 0),
|
||||
action(function() table.insert(queue, 10) end, 10)
|
||||
}
|
||||
|
||||
CHECK(testkit.seq(queue, { -1, 0, 2.5, 10, 100 }))
|
||||
end
|
||||
end)
|
||||
|
||||
TEST("changed()", wrap_root(function()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue