public void EmprestimoRepositorio_Get_ShouldBeOk()
        {
            int        idSearch = 1;
            Emprestimo result   = _service.Get(idSearch);

            result.Should().NotBeNull();
            result.Id.Should().Be(idSearch);
        }
Exemplo n.º 2
0
        public ActionResult Devolucao(int id)
        {
            var emprestimo = (_emprestimoService.Get() as IQueryable <Emprestimo>).Where(x => x.JogoId == id && x.Ativo == true).FirstOrDefault();

            var amigo = _amigoService.Get(emprestimo.AmigoId);
            var model = new ModelEmprestimo()
            {
                Emprestimo = emprestimo, Amigos = new List <Amigo>()
                {
                    amigo
                }
            };

            //var amigo = _jogoService.Get(id);
            return(View(model));
        }