@Override
    public void registerBeanDefinitions(final AnnotationMetadata metadata, final BeanDefinitionRegistry registry) {
        registerShenyuClients(metadata, registry);
    }
@Test
    public void registerBeanDefinitionsTest() {
        AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext();
        final ShenyuSdkClient client = spy(ShenyuSdkClient.class);
        ((DefaultListableBeanFactory) context.getBeanFactory()).setAllowBeanDefinitionOverriding(false);
        context.register(TopLevelSubLevelTestConfig.class);
        context.register(SpringMvcContract.class);
        context.registerBean("shenyuSdkClient", ShenyuSdkClient.class, () -> client);

        context.refresh();

        final TopLevelSubLevelTestConfig.TopLevelClient topClient = context.getBean(TopLevelSubLevelTestConfig.TopLevelClient.class);
        final SubLevelClient subClient = context.getBean(SubLevelClient.class);
        assertNotNull(topClient);
        assertNotNull(subClient);
    }