Ejemplo n.º 1
0
        public void ImplementedBy(Type genericServiceImplementationTypeDefinition)
        {
            var registration = new GenericImplementation(
                genericServiceImplementationTypeDefinition,
                _genericServiceTypeDefinitions);

            Registerer.AddRegistration(_registerer, registration);
        }
Ejemplo n.º 2
0
        public async Task Build_Should_Create_Proxy_That_Handles_Generic_Interface_3(int value)
        {
            var target = new GenericImplementation();
            var actor  = _Factory.Build <IGenericInterface <string> >(target);

            var res = await actor.GetResultString(value);

            res.Should().Be($"{value}");
            target.LastCallingThread.Should().NotBe(Thread.CurrentThread);
        }