mirror of
https://github.com/OpenMW/openmw.git
synced 2025-11-29 11:34:29 +00:00
Add integration test
This commit is contained in:
parent
823dc6a896
commit
d147006c64
2 changed files with 8 additions and 0 deletions
|
|
@ -7,6 +7,13 @@ local vfs = require('openmw.vfs')
|
||||||
local world = require('openmw.world')
|
local world = require('openmw.world')
|
||||||
local I = require('openmw.interfaces')
|
local I = require('openmw.interfaces')
|
||||||
|
|
||||||
|
testing.registerGlobalTest('crash in lua coroutine when accessing type (#8757)', function()
|
||||||
|
local co = coroutine.wrap(function()
|
||||||
|
testing.expectEqual(tostring(world.players[1].type), 'Player')
|
||||||
|
end)
|
||||||
|
co()
|
||||||
|
end)
|
||||||
|
|
||||||
testing.registerGlobalTest('timers', function()
|
testing.registerGlobalTest('timers', function()
|
||||||
testing.expectAlmostEqual(core.getGameTimeScale(), 30, 'incorrect getGameTimeScale() result')
|
testing.expectAlmostEqual(core.getGameTimeScale(), 30, 'incorrect getGameTimeScale() result')
|
||||||
testing.expectAlmostEqual(core.getSimulationTimeScale(), 1, 'incorrect getSimulationTimeScale result')
|
testing.expectAlmostEqual(core.getSimulationTimeScale(), 1, 'incorrect getSimulationTimeScale result')
|
||||||
|
|
|
||||||
|
|
@ -61,6 +61,7 @@ local function registerGlobalTest(name, description)
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
registerGlobalTest('crash in lua coroutine when accessing type (#8757)')
|
||||||
registerGlobalTest('timers')
|
registerGlobalTest('timers')
|
||||||
registerGlobalTest('teleport')
|
registerGlobalTest('teleport')
|
||||||
registerGlobalTest('getGMST')
|
registerGlobalTest('getGMST')
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue