Issue #3138 role api unit test