Example #1
0
        public void DadoUmaContaVazia_IsInvalid()
        {
            var command = new CreateContaCommand("");

            var handler = new CreateContaHandler(new FakeRepositoryConta());
            var result  = handler.Handle(command).Result;

            Assert.AreNotEqual(0, result.Notifications.Count);
            Assert.AreEqual(true, result.Invalid);
        }
Example #2
0
 public ContaController(IContaRepository contaRepository, CreateContaHandler createContaHandler)
 {
     _contaRepository    = contaRepository;
     _createContaHandler = createContaHandler;
 }