@Test
public void testDeleteProviderResourceGroupRoles() {

    ZMSClient client = createClient(systemAdminUser);
    ZMSRDLGeneratedClient c = Mockito.mock(ZMSRDLGeneratedClient.class);
    client.setZMSRDLGeneratedClient(c);
    try {
        Mockito.when(c.deleteProviderResourceGroupRoles("tenantDomain", "providerDomain", "providerServiceName",
                "resourceGroup", AUDIT_REF)).thenThrow(new NullPointerException());
        client.deleteProviderResourceGroupRoles("tenantDomain", "providerDomain", "providerServiceName",
                "resourceGroup", AUDIT_REF);
        fail();
    } catch (ResourceException ex) {
        assertTrue(true);
    }
    try {
        Mockito.when(c.deleteProviderResourceGroupRoles("tenantDomain2", "providerDomain2", "providerServiceName2",
                "resourceGroup2", AUDIT_REF)).thenThrow(new ResourceException(400));
        client.deleteProviderResourceGroupRoles("tenantDomain2", "providerDomain2", "providerServiceName2",
                "resourceGroup2", AUDIT_REF);
        fail();
    } catch (ResourceException ex) {
        assertTrue(true);
    }
}