/** * @expectedException BusinessLogicException */ public function testNuevaOrdenSinCreditoSuficiente() { $s = ServiciosController::Nuevo($codigo_servicio = "testNuevoServicio-2db94458" . time(), $compra_en_mostrador = false, $costo_estandar = 0, $metodo_costeo = "precio", $nombre_servicio = "testNuevoServicio-2db94458" . time(), $activo = true, $clasificaciones = null, $control_de_existencia = null, $descripcion_servicio = null, $empresas = null, $extra_params = null, $foto_servicio = null, $garantia = null, $impuestos = null, $precio = 1542.15, $retenciones = null, $sucursales = null); $c = ClientesController::nuevo("testNuevaOrdenCliente -2db94458" . time()); $o = ServiciosController::NuevaOrden($c["id_cliente"], $s["id_servicio"]); }
public function testNuevoAval() { //Crear un cliente $a = ClientesController::nuevo(time() . "cliente"); //crear su aval $b = ClientesController::nuevo(time() . "aval"); //asignar el aval al cliente ClientesController::NuevoAval(array(array("id_aval" => $b["id_cliente"], "tipo_aval" => "prendario")), $a["id_cliente"]); $r = ClienteAvalDAO::getByPK($a["id_cliente"], $b["id_cliente"]); $this->assertNotNull($r); }