1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-06-25 20:41:33 +00:00

Format Lua tests code

This commit is contained in:
elsid 2024-06-22 02:52:02 +02:00
parent 1dd15613dd
commit 73c347f732
No known key found for this signature in database
GPG key ID: 4DE04C198CBA7625

View file

@ -29,7 +29,9 @@ local function testTimers()
ts2 = core.getSimulationTime() - startSimulationTime
end)
while not (ts1 and ts2 and th1 and th2) do coroutine.yield() end
while not (ts1 and ts2 and th1 and th2) do
coroutine.yield()
end
testing.expectGreaterOrEqual(th1, 36, 'async:newGameTimer failed')
testing.expectGreaterOrEqual(ts1, 0.5, 'async:newSimulationTimer failed')
@ -101,7 +103,9 @@ end
local function testRecordStore(store, storeName, skipPairs)
testing.expect(store.records)
local firstRecord = store.records[1]
if not firstRecord then return end
if not firstRecord then
return
end
testing.expectEqual(firstRecord.id, store.records[firstRecord.id].id)
local status, _ = pcall(function()
for index, value in ipairs(store.records) do