@Test
public void test_getAppRoleObjFromString() throws IOException {

    String [] policies = {"default"};
    String jsonStr = "{\"role_name\":\"role1\",\"policies\":[\"default\"],\"bind_secret_id\":true,\"secret_id_num_uses\":\"1\",\"secret_id_ttl\":\"100m\",\"token_num_uses\":0,\"token_ttl\":null,\"token_max_ttl\":null}";
    AppRole appRole = new AppRole("role1", policies, true, 1, 100, 0);
    when(JSONUtil.getObj(jsonStr, AppRole.class)).thenReturn(appRole);
    AppRole appRoleActual = ControllerUtil.getAppRoleObjFromString(jsonStr);
    assertEquals(appRole, appRoleActual);
}