Esempio n. 1
0
        public CalculadoraJurosHandlerTests()
        {
            var autoMoqer = new AutoMoqer();

            handler     = autoMoqer.Create <CalculadoraJurosHandler>();
            jurosClient = autoMoqer.GetMock <IJurosClient>();
        }
Esempio n. 2
0
        public async Task <IActionResult> Calcular(
            [FromServices] CalculadoraJurosHandler handler,
            [SwaggerParameter(Required = true)][FromQuery] CalculoCommand command)
        {
            var result = await handler.Calcular(command);

            return(Ok(result));
        }