xref: /PHP-8.2/ext/soap/tests/bugs/bug50698_3.phpt (revision 7f2f0c00)
1--TEST--
2Request #50698_3 (SoapClient should handle wsdls with some incompatible endpoints -- EDGECASE: Large set of endpoints all incompatible.)
3--EXTENSIONS--
4soap
5--INI--
6soap.wsdl_cache_enabled=0
7--FILE--
8<?php
9try {
10    new SoapClient(__DIR__ . '/bug50698_3.wsdl');
11    echo "Call: \"new SoapClient(__DIR__.'/bug50698_3.wsdl');\" should throw an exception of type 'SoapFault'";
12} catch (SoapFault $e) {
13    if ($e->faultcode == 'WSDL' && $e->faultstring == 'SOAP-ERROR: Parsing WSDL: Could not find any usable binding services in WSDL.') {
14        echo "ok\n";
15    } else {
16        echo "Call: \"new SoapClient(__DIR__.'/bug50698_3.wsdl');\" threw a SoapFault with an incorrect faultcode or faultmessage.";
17        print_r($e);
18    }
19}
20?>
21--EXPECT--
22ok
23