public void InsertOrUpdate_Insert_OK() { GEHD_INCIDENCIAS incidencia = new GEHD_INCIDENCIAS { IdIncidencia = 0, Bloque = "xXx", ComputaEstadisticas = "c", Concepto = "c", Estado = "camb", FechaAlta = DateTime.Today, FechaCierre = DateTime.Today, FechaCierreCECA = DateTime.Today, FechaEstimada = DateTime.Today, FechaModificacion = DateTime.Today, FechaReportadoInterno = DateTime.Today, FechaReportadoProveedor = DateTime.Today, IdCorteServicio = 1, IdDepartamento = "u", IdEntidad = "0000", IdProducto = 1, Incidencia = "i", IncidenciaCodCECA = "C", IncidenciaPS = "p", NombreContacto = "n", Persona = "p", PersonaCierre = "p", Prioridad = "p", Respuesta = "r", StatusProveedor = "s", SubEntidad = "s", Subject = "s", TextoBusquedaRapida = "s" }; object pks = new { IdIncidencia = 0 }; int result = instance.InstertOrUpdate(incidencia, pks); Assert.Equal(1, result); }
public int InstertOrUpdate(TEntity entity, object pks) { var result = dpRepository.InstertOrUpdate(entity, pks); return(result); }