### Question:
DoubleDefinitionsRegistrationContext { public void registerMock(BeanDefinitionRegistry registry, String definitionName, DoubleDefinition mockDefinition) { registerBeanDefinition( mockDefinition, definitionName, registry, buildBeanDefinition(CREATE_MOCK_FACTORY_METHOD, mockDefinition, mockDefinition)); }  void registerSpyReplacement(DoubleDefinition spyDefinition); void registerMock(BeanDefinitionRegistry registry, String definitionName, DoubleDefinition mockDefinition); void registerMock(BeanDefinitionRegistry registry, DoubleDefinition mockDefinition); void registerSpy(BeanDefinitionRegistry registry, DoubleDefinition spyDefinition); boolean isBeanDefinitionRegisteredForDouble(DoubleDefinition definition); static final String BEAN_NAME; }### Answer:
@Test public void should_register_mock_creation() { final DefaultListableBeanFactory beanFactory = new DefaultListableBeanFactory(); final DoubleDefinition mockDefinition = DoubleDefinition.builder() .name("mock") .doubleClass(Object.class) .build(); registrationContext.registerMock(beanFactory, mockDefinition); bootstrapApplicationContext(beanFactory); Mockito .verify(doubleFactory) .createMock(mockDefinition); }