Add module register functions and adjust iOS and Mac test cases