Esempio n. 1
0
 public function __construct()
 {
     if (function_exists('env')) {
         $this->setShopId(env('TRAY_SHOPID'));
         $this->setLogin(env('TRAY_LOGIN'));
         $this->setPwd(env('TRAY_PWD'));
         $this->setWsdl(env('TRAY_WSDL'));
     }
     $builder = SoapClientBuilder::createWithDefaults()->withEncoding('ISO-8859-1')->withTrace()->withExceptions()->withSoapVersion11()->withWsdl($this->wsdl);
     $this->soapClient = $builder->build();
 }
 public function testCreateWithDefaults()
 {
     $builder = SoapClientBuilder::createWithDefaults();
     $this->assertInstanceOf('BeSimple\\SoapClient\\SoapClientBuilder', $builder);
     $this->assertEquals($this->mergeOptions(array('soap_version' => SOAP_1_2, 'encoding' => 'UTF-8', 'features' => SOAP_SINGLE_ELEMENT_ARRAYS, 'user_agent' => 'BeSimpleSoap')), $builder->getSoapOptions());
 }
 public static function createWithDefaults()
 {
     return parent::createWithDefaults()->withUserAgent('millennium-php')->withDefaultClassmap()->withSoapVersion12();
 }