mirror of
https://gitlab.freedesktop.org/pipewire/wireplumber.git
synced 2025-12-26 14:10:04 +01:00
- WirePlumber Lua now facilitates Lua libraries/modules, utilize this and create modules. Add some tests around this functionality. - Create policy-hooks.lua containing all the hooks to find-target events - Create policy-utils.lua module and push all the policy utility functions to it. - Create common-utils.lua module and push the common utility functions to it. - Remove all the above functionality from policy-node.lua and clean it up.
26 lines
426 B
Lua
26 lines
426 B
Lua
local testlib = {}
|
|
|
|
testlib.table1 = {}
|
|
|
|
testlib.table1 ["test-key"] = "test-value"
|
|
|
|
function testlib.test_add_ten (x)
|
|
return x + 10
|
|
end
|
|
|
|
function testlib.get_empty_table (key)
|
|
testlib.table1 [key] = {}
|
|
return testlib.table1 [key]
|
|
end
|
|
|
|
function testlib.set_table (key, value)
|
|
testlib.table1 [key] = value
|
|
end
|
|
|
|
function testlib.get_table (key)
|
|
return testlib.table1 [key]
|
|
end
|
|
|
|
Log.info ("in testlib")
|
|
|
|
return testlib
|