diff --git a/test/test_lume.lua b/test/test_lume.lua index 01ec888..b3cd6ed 100644 --- a/test/test_lume.lua +++ b/test/test_lume.lua @@ -249,6 +249,16 @@ tests["lume.once"] = function() testeq( f(5), nil ) end +-- lume.combine +tests["lume.combine"] = function() + local acc = 0 + local a = function(x, y) acc = acc + x + y end + local b = function(x, y) acc = acc + x * y end + local fn = lume.combine(a, b) + fn(10, 20) + testeq( acc, 230 ) +end + -- lume.time tests["lume.time"] = function() local t, a, b, c = lume.time(function(x) return 50, 60, x end, 70)