From 7d3e2bd2c4cfd1296d1d6f996d7548de26540d41 Mon Sep 17 00:00:00 2001 From: Josh Haberman Date: Fri, 15 Feb 2013 16:27:18 -0800 Subject: Sync with 8 months of Google-internal development. Many things have changed and been simplified. The memory-management story for upb_def and upb_handlers is much more robust; upb_def and upb_handlers should be fairly stable interfaces now. There is still much work to do for the runtime component (upb_sink). --- bindings/lua/lunitx/lunitx.lua | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 bindings/lua/lunitx/lunitx.lua (limited to 'bindings/lua/lunitx/lunitx.lua') diff --git a/bindings/lua/lunitx/lunitx.lua b/bindings/lua/lunitx/lunitx.lua new file mode 100644 index 0000000..7656e6a --- /dev/null +++ b/bindings/lua/lunitx/lunitx.lua @@ -0,0 +1,21 @@ +local atexit = require "atexit" +local lunit = require "lunit" + +--for k,v in pairs(debug.getinfo(1,"S")) do print(k,v) end +-- autonameing +-- module("bcrc-test", lunit.testcase, package.seeall) + +atexit(function() + local _, emsg = xpcall(function() + lunit.main(arg) + end, debug.traceback) + if emsg then + print(emsg) + os.exit(1) + end + if lunit.stats.failed > 0 or lunit.stats.errors > 0 then + os.exit(1) + end +end) + +return lunit -- cgit v1.2.3