1234567891011121314151617181920212223242526 |
- dofile('../modpol.lua');
- modpol.orgs.reset()
- test_org = modpol.instance:add_org('test_org')
- test_org:add_member('luke')
- test_org:add_member('nathan')
- test_org:set_policy("add_member", "consent", false);
- new_request = {
- user = "josh",
- type = "add_member",
- params = {"josh"}
- }
- request_id = test_org:make_request(new_request)
- -- process_id = test_org:create_process("consent", request_id)
- for id, process in ipairs(test_org.processes) do
- process:approve('luke', true)
- process:approve('nathan', true)
- end
- -- process = test_org.processes[process_id]
- -- process:approve("luke", true)
- -- process:approve("nathan", true)
|