@Test
    void verifyChainOps() {
        val appCtx = new StaticApplicationContext();
        appCtx.refresh();

        val chain = new DefaultChainingServiceRegistry(appCtx);
        val registry1 = new InMemoryServiceRegistry(appCtx);
        chain.addServiceRegistry(registry1);

        val registry2 = new InMemoryServiceRegistry(appCtx);
        chain.addServiceRegistry(registry2);

        val service = newService();
        chain.save(service);

        assertNotNull(registry1.findServiceById(service.getId()));
        assertNotNull(registry2.findServiceById(service.getId()));

        chain.delete(service);

        assertNull(registry1.findServiceById(service.getId()));
        assertNull(registry2.findServiceById(service.getId()));
    }
This is {@link DefaultChainingServiceRegistryTests}.

@author Misagh Moayyed
@since 6.3.0
core/cas-server-core-services-registry/src/test/java/org/apereo/cas/services/DefaultChainingServiceRegistryTests.java