diff options
author | daurnimator <quae@daurnimator.com> | 2017-05-11 14:02:23 +1000 |
---|---|---|
committer | daurnimator <quae@daurnimator.com> | 2017-05-11 15:19:18 +1000 |
commit | e7cf17565e26dc5c4a100688526b0dfed1220e44 (patch) | |
tree | ee4606b23f9c62ecf0e6da20dcbf0472d5339fd9 /tests/ltablib.js | |
parent | be3f9810115cbaded69be37ebc3d088ee252a225 (diff) | |
download | fengari-e7cf17565e26dc5c4a100688526b0dfed1220e44.tar.gz fengari-e7cf17565e26dc5c4a100688526b0dfed1220e44.tar.bz2 fengari-e7cf17565e26dc5c4a100688526b0dfed1220e44.zip |
Move luaL_openlibs from lauxlib to lualib
Diffstat (limited to 'tests/ltablib.js')
-rw-r--r-- | tests/ltablib.js | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/tests/ltablib.js b/tests/ltablib.js index 15f9e57..8789f9e 100644 --- a/tests/ltablib.js +++ b/tests/ltablib.js @@ -5,8 +5,10 @@ const test = require('tape'); const tests = require("./tests.js"); const toByteCode = tests.toByteCode; -const lauxlib = require("../src/lauxlib.js"); -const lua = require('../src/lua.js'); +const lua = require('../src/lua.js'); +const lauxlib = require('../src/lauxlib.js'); +const lualib = require('../src/lualib.js'); + const inttable2array = function(t) { let a = []; @@ -32,7 +34,7 @@ test('table.concat', function (t) { L = lauxlib.luaL_newstate(); - lauxlib.luaL_openlibs(L); + lualib.luaL_openlibs(L); lua.lua_load(L, null, bc, lua.to_luastring("test-table.concat"), lua.to_luastring("binary")); @@ -61,7 +63,7 @@ test('table.pack', function (t) { L = lauxlib.luaL_newstate(); - lauxlib.luaL_openlibs(L); + lualib.luaL_openlibs(L); lua.lua_load(L, null, bc, lua.to_luastring("test-table.pack"), lua.to_luastring("binary")); @@ -92,7 +94,7 @@ test('table.unpack', function (t) { L = lauxlib.luaL_newstate(); - lauxlib.luaL_openlibs(L); + lualib.luaL_openlibs(L); lua.lua_load(L, null, bc, lua.to_luastring("test-table.unpack"), lua.to_luastring("binary")); @@ -136,7 +138,7 @@ test('table.insert', function (t) { L = lauxlib.luaL_newstate(); - lauxlib.luaL_openlibs(L); + lualib.luaL_openlibs(L); lua.lua_load(L, null, bc, lua.to_luastring("test-table.insert"), lua.to_luastring("binary")); @@ -170,7 +172,7 @@ test('table.remove', function (t) { L = lauxlib.luaL_newstate(); - lauxlib.luaL_openlibs(L); + lualib.luaL_openlibs(L); lua.lua_load(L, null, bc, lua.to_luastring("test-table.remove"), lua.to_luastring("binary")); @@ -203,7 +205,7 @@ test('table.move', function (t) { L = lauxlib.luaL_newstate(); - lauxlib.luaL_openlibs(L); + lualib.luaL_openlibs(L); lua.lua_load(L, null, bc, lua.to_luastring("test-table.move"), lua.to_luastring("binary")); @@ -236,7 +238,7 @@ test('table.sort (<)', function (t) { L = lauxlib.luaL_newstate(); - lauxlib.luaL_openlibs(L); + lualib.luaL_openlibs(L); lua.lua_load(L, null, bc, lua.to_luastring("test-table.sort"), lua.to_luastring("binary")); @@ -269,7 +271,7 @@ test('table.sort with cmp function', function (t) { L = lauxlib.luaL_newstate(); - lauxlib.luaL_openlibs(L); + lualib.luaL_openlibs(L); lua.lua_load(L, null, bc, lua.to_luastring("test-table.sort"), lua.to_luastring("binary")); |