MCPcopy Create free account
hub / github.com/PolygonTek/BlueshiftEngine / TestLua

Function TestLua

Source/TestBase/TestLua.cpp:326–363  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

324}
325
326void TestLua() {
327 LuaCpp::State lua(true);
328
329 lua.HandleExceptionsWith([](int status, std::string msg, std::exception_ptr exception) {
330 const char *statusStr = "";
331 switch (status) {
332 case LUA_ERRRUN:
333 statusStr = "LUA_ERRRUN";
334 break;
335 case LUA_ERRSYNTAX:
336 statusStr = "LUA_ERRSYNTAX";
337 break;
338 case LUA_ERRMEM:
339 statusStr = "LUA_ERRMEM";
340 break;
341#if LUA_VERSION_NUM >= 502
342 case LUA_ERRGCMM:
343 statusStr = "LUA_ERRGCMM";
344 break;
345#endif
346 case LUA_ERRERR:
347 statusStr = "LUA_ERRERR";
348 break;
349 }
350 BE_ERRLOG("%s - %s\n", statusStr, msg.c_str());
351 });
352
353 TestLuaFunction(lua);
354 TestCppFunction(lua);
355 TestInheritance(lua);
356 TestPolymorphism(lua);
357 TestObject(lua);
358 TestCallByReference(lua);
359 TestVec3(lua);
360 TestTableEnumeration(lua);
361 TestModule(lua);
362 TestCompile(lua);
363}

Callers

nothing calls this directly

Calls 12

TestLuaFunctionFunction · 0.85
TestCppFunctionFunction · 0.85
TestInheritanceFunction · 0.85
TestPolymorphismFunction · 0.85
TestObjectFunction · 0.85
TestCallByReferenceFunction · 0.85
TestVec3Function · 0.85
TestTableEnumerationFunction · 0.85
TestModuleFunction · 0.85
TestCompileFunction · 0.85
HandleExceptionsWithMethod · 0.80
c_strMethod · 0.45

Tested by

no test coverage detected