summaryrefslogtreecommitdiff
path: root/tests/lcorolib.js
diff options
context:
space:
mode:
Diffstat (limited to 'tests/lcorolib.js')
-rw-r--r--tests/lcorolib.js17
1 files changed, 9 insertions, 8 deletions
diff --git a/tests/lcorolib.js b/tests/lcorolib.js
index b18b528..342b560 100644
--- a/tests/lcorolib.js
+++ b/tests/lcorolib.js
@@ -5,9 +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 lstate = require('../src/lstate.js');
+const lua = require('../src/lua.js');
+const lauxlib = require('../src/lauxlib.js');
+const lualib = require('../src/lualib.js');
+const lstate = require('../src/lstate.js');
test('coroutine.create, coroutine.yield, coroutine.resume', function (t) {
@@ -31,7 +32,7 @@ test('coroutine.create, coroutine.yield, coroutine.resume', function (t) {
L = lauxlib.luaL_newstate();
- lauxlib.luaL_openlibs(L);
+ lualib.luaL_openlibs(L);
lua.lua_load(L, null, bc, lua.to_luastring("test-coroutine"), lua.to_luastring("binary"));
@@ -74,7 +75,7 @@ test('coroutine.status', function (t) {
L = lauxlib.luaL_newstate();
- lauxlib.luaL_openlibs(L);
+ lualib.luaL_openlibs(L);
lua.lua_load(L, null, bc, lua.to_luastring("test-coroutine.status"), lua.to_luastring("binary"));
@@ -115,7 +116,7 @@ test('coroutine.isyieldable', function (t) {
L = lauxlib.luaL_newstate();
- lauxlib.luaL_openlibs(L);
+ lualib.luaL_openlibs(L);
lua.lua_load(L, null, bc, lua.to_luastring("test-coroutine.isyieldable"), lua.to_luastring("binary"));
@@ -156,7 +157,7 @@ test('coroutine.running', function (t) {
L = lauxlib.luaL_newstate();
- lauxlib.luaL_openlibs(L);
+ lualib.luaL_openlibs(L);
lua.lua_load(L, null, bc, lua.to_luastring("test-coroutine.running"), lua.to_luastring("binary"));
@@ -197,7 +198,7 @@ test('coroutine.wrap', function (t) {
L = lauxlib.luaL_newstate();
- lauxlib.luaL_openlibs(L);
+ lualib.luaL_openlibs(L);
lua.lua_load(L, null, bc, lua.to_luastring("test-coroutine.wrap"), lua.to_luastring("binary"));