def METHOD_NAME(self):
    # Instantiate a DPS Service Client using a connection string
    from azure.iot.deviceprovisioning import DeviceProvisioningClient
    dps_service_client = DeviceProvisioningClient.from_connection_string(
        self.connection_string
    )
    # Delete enrollment groups
    dps_service_client.enrollment_group.delete(id=self.x509_enrollment_group_id)
    dps_service_client.enrollment_group.delete(
        id=self.symmetric_enrollment_group_id
    )