Added test for lume.lambda() caching

This commit is contained in:
rxi 2014-03-15 21:58:35 +00:00
parent be40cd6276
commit 2c3be23a2b

View File

@ -256,6 +256,7 @@ end
-- lume.lambda
tests["lume.lambda"] = function()
testeq( lume.lambda "x->x*x"(10), 100 )
testeq( lume.lambda "x->x*x"(20), 400 )
testeq( lume.lambda "x,y -> 2*x+y"(10,5), 25 )
testeq( lume.lambda "a, b -> a / b"(1, 2), .5 )
testeq( lume.lambda "a -> 'hi->' .. a"("doggy"), "hi->doggy" )