public void Exibir_View_Create() { _itemValor = new ItemValorController(_gerenciadorDeItemValor); var result = _itemValor.Create(1) as ViewResult; Assert.IsInstanceOfType(result, typeof(ViewResult)); }
public void Enviar_Create() { _itemValor = new ItemValorController(_gerenciadorDeItemValor); var itemValorViewModel = Mapeador.Mapear <ItemValor, ItemValorViewModel>(ItemValorStub.NovoItemValor()); var result = _itemValor.Create(itemValorViewModel) as RedirectToRouteResult; Assert.AreEqual("Index", result.RouteValues["action"]); }