@Test
public void passesRecordingCodeAndRegistersTheGenerationInformationInRegistry() {

    final String expected = "something(2, 3);";
    FunctionRegistry<RegistryInformation<GenerationFunctionInformation>> functionRegistry = mock(FunctionRegistry.class);
    RegistryInformation<GenerationFunctionInformation> registryInformation = mock(RegistryInformation.class);
    when(functionRegistry.generate(registryInformation)).thenReturn(expected);
    IncludeInvokeGenerator<RegistryInformation<GenerationFunctionInformation>> includeInvokeGenerator =
            new IncludeInvokeGenerator<>(functionRegistry);
    String actual = includeInvokeGenerator.generate(registryInformation);
    assertEquals(expected, actual);
    verify(functionRegistry).register(registryInformation);
}