@Test
    void verifyDeletingServices() {
        getRegisteredServiceTypes().forEach(type -> {
            serviceRegistry.save(buildRegisteredServiceInstance(400, type)
                .setId(RegisteredServiceDefinition.INITIAL_IDENTIFIER_VALUE));
            serviceRegistry.save(buildRegisteredServiceInstance(401, type)
                .setId(RegisteredServiceDefinition.INITIAL_IDENTIFIER_VALUE));
            val services = serviceRegistry.load();
            services.forEach(registeredService -> serviceRegistry.delete(registeredService));
            assertEquals(0, serviceRegistry.load().size());
        });
    }
Abstracted service registry tests for all implementations.

@author Timur Duehr
@since 5.3.0
core/cas-server-core-services/src/test/java/org/apereo/cas/services/AbstractServiceRegistryTests.java