summaryrefslogtreecommitdiff
path: root/server/test/full/example.lua
blob: cf23335cb7fc0a69a58e7fce6a040d58c506aca0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
local fs = require 'bee.filesystem'

TEST(io.load(ROOT / 'src' / 'vm' / 'vm.lua'))

-- 临时
local function testIfExit(path)
    local buf = io.load(fs.path(path))
    if buf then
        local clock = os.clock()
        for _ = 1, 10 do
            TEST(buf)
        end
        print('基准测试耗时:', os.clock() - clock)
    end
end
testIfExit(ROOT / 'test' / 'example' / 'vm.txt')