aboutsummaryrefslogtreecommitdiff
path: root/test/glum_test.lua
diff options
context:
space:
mode:
authorAlexander Pickering <alexandermpickering@gmail.com>2017-03-13 15:38:23 -0400
committerAlexander Pickering <alexandermpickering@gmail.com>2017-03-13 15:38:23 -0400
commitf687e914e07094b1eef11d84dab2e069a9298df5 (patch)
treed74600b3afebd028689baa1c306432fac5030f9f /test/glum_test.lua
parentf96040eb138efdc8f13521bade5bf8bd299bb9fb (diff)
downloadglum-f687e914e07094b1eef11d84dab2e069a9298df5.tar.gz
glum-f687e914e07094b1eef11d84dab2e069a9298df5.tar.bz2
glum-f687e914e07094b1eef11d84dab2e069a9298df5.zip
Started updateing unit tests
Diffstat (limited to 'test/glum_test.lua')
-rw-r--r--test/glum_test.lua21
1 files changed, 12 insertions, 9 deletions
diff --git a/test/glum_test.lua b/test/glum_test.lua
index e9447dd..2fdceb9 100644
--- a/test/glum_test.lua
+++ b/test/glum_test.lua
@@ -871,18 +871,21 @@ local str2 = [=[
--[[/////////////////
]]
-local foo = 1
-if foo then print("bar") end
-local function something(foo, bar)
- print("foobar")
-end
-something(foo,4)
+local obj = {}
+obj.subobj = {}
+obj.bar = 1
+obj.subobj.foo = function(foo,fizz)
+ foo.bar = foo.bar + 1
+ print(fizz,foo.bar)
+end
+obj.subobj.foo(obj.subobj,"something")
]=]
-local min = glum.minify(str)
+--local min = glum.minify(str2)
--local comp = ugly.uglify(min)
-print(min)
-print(string.format("Old size:%d\nNew size:%d",#str,#min))
+--print(min)
+--print(string.format("Old size:%d\nNew size:%d",#str,#min))
+print(string.dump(CompileString(str2)()))
--[[
local fuzzel = loadstring(f)()