Example #1
0
 public function testSoapVersion()
 {
     $server = new Server();
     $this->assertEquals(SOAP_1_2, $server->getSoapVersion());
     $server->setSoapVersion(SOAP_1_1);
     $this->assertEquals(SOAP_1_1, $server->getSoapVersion());
     $this->setExpectedException('Zend\\Soap\\Exception\\InvalidArgumentException', 'Invalid soap version specified');
     $server->setSoapVersion('bogus');
 }
Example #2
0
 /**
  * Local client constructor
  *
  * @param SOAPServer $server
  * @param string $wsdl
  * @param array $options
  */
 public function __construct(SOAPServer $server, $wsdl, $options = null)
 {
     $this->server = $server;
     // Use Server specified SOAP version as default
     $this->setSoapVersion($server->getSoapVersion());
     parent::__construct($wsdl, $options);
 }
Example #3
0
 public function testSoapVersion()
 {
     $server = new Server();
     $this->assertEquals(SOAP_1_2, $server->getSoapVersion());
     $server->setSoapVersion(SOAP_1_1);
     $this->assertEquals(SOAP_1_1, $server->getSoapVersion());
     try {
         $server->setSoapVersion('bogus');
         $this->fail('Invalid soap versions should fail');
     } catch (\Exception $e) {
         // success
     }
 }