Vale, empiezo a responderme yo mismo.
Gran cagada: Las pruebas se han ido al entorno de producción. Ahora a ver cómo arreglamos esto...
Importé el WSDL y lo retoqué para poder seleccionar si se enviaba al entorno de pruebas o a productivo:
Código Delphi
[-]const
URLVERIFACTUPROD = 'h_t_t_p_s://www2.agenciatributaria.gob.es/wlpl/TIKE-CONT/ws/SistemaFacturacion/VerifactuSOAP';
URLVERIFACTUPRUEBAS = 'h_t_t_p_s://prewww2.aeat.es/wlpl/TIKE-CONT/ws/SistemaFacturacion/VerifactuSOAP';
URLREQUERIMIENTOPROD = 'h_t_t_p_s://www2.agenciatributaria.gob.es/wlpl/TIKE-CONT/ws/SistemaFacturacion/RequerimientoSOAP';
URLREQUERIMIENTOPRUEBAS = 'h_t_t_p_s://prewww2.aeat.es/wlpl/TIKE-CONT/ws/SistemaFacturacion/RequerimientoSOAP';
Añado un parámetro a la función GetsfPortTypeVerifactu y selecciono la URL:
Código Delphi
[-]function GetsfPortTypeVerifactu(UseWSDL, pruebas: Boolean; Addr: string; HTTPRIO: THTTPRIO): sfPortTypeVerifactu;
const
defWSDL = 'h_t_t_p_s://prewww2.aeat.es/static_files/common/internet/dep/aplicaciones/es/aeat/tikeV1.0/cont/ws/SistemaFacturacion.wsdl';
defSvc = 'sfVerifactu';
defPrt = 'SistemaVerifactu';
var
RIO: THTTPRIO;
defURL : String;
begin
if pruebas then
defURL := URLVERIFACTUPRUEBAS
else
defURL := URLVERIFACTUPROD;
...
Y cuando creo el servicio le paso el parámetro de pruebas a True:
Código Delphi
[-] Servicio := GetsfPortTypeVerifactu(True, True);
Porqué se ha ido la comunicación a www1.agenciatributaria.gob.es/ ????
Alguna luz al respecto?
Gracias de antemano