protected void DeleteRowButton_Click(Object sender, GridViewDeleteEventArgs e) { TableCell cell = gridView1.Rows[e.RowIndex].Cells[1]; int id = Convert.ToInt32(cell.Text); Funcionario funcionario = new Funcionario(); funcionario.Id = id; funcionario.Excluir(); this.redirecionarMesmaPagina(); }
public void ExclusaoFuncionario() { Funcionario funcionario = new Funcionario(); funcionario.Id = 1; Assert.IsTrue(funcionario.Excluir()); }