Skip to content
This repository has been archived by the owner on Jan 31, 2020. It is now read-only.

Commit

Permalink
Merge branch 'hotfix/31' into develop
Browse files Browse the repository at this point in the history
Forward port #31
  • Loading branch information
weierophinney committed Jan 29, 2018
2 parents f82660a + 4a6c892 commit a6ae66a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ All notable changes to this project will be documented in this file, in reverse
- [#42](https://github.com/zendframework/zend-soap/pull/42) adds support for PHP
versions 7.1 and 7.2.

- [#31](https://github.com/zendframework/zend-soap/pull/31) adds support for
`xsd:date` elements.

### Changed

- Nothing.
Expand Down
3 changes: 3 additions & 0 deletions src/Wsdl.php
Original file line number Diff line number Diff line change
Expand Up @@ -695,6 +695,9 @@ public function getType($type)
case 'mixed':
return self::XSD_NS . ':anyType';

case 'date':
return self::XSD_NS . ':date';

case 'void':
return '';

Expand Down
2 changes: 2 additions & 0 deletions test/WsdlTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -631,6 +631,7 @@ public function testGetType()
$this->assertEquals('soap-enc:Array', $this->wsdl->getType('array'), 'soap-enc:Array detection failed.');
$this->assertEquals('xsd:struct', $this->wsdl->getType('object'), 'xsd:struct detection failed.');
$this->assertEquals('xsd:anyType', $this->wsdl->getType('mixed'), 'xsd:anyType detection failed.');
$this->assertEquals('xsd:date', $this->wsdl->getType('date'), 'xsd:date detection failed.');
$this->assertEquals('', $this->wsdl->getType('void'), 'void detection failed.');
}

Expand Down Expand Up @@ -787,6 +788,7 @@ public function testCaseOfDocBlockParamsDosNotMatterForSoapTypeDetectionZf3910()
$this->assertEquals("xsd:int", $this->wsdl->getType("INTEGER"));
$this->assertEquals("xsd:float", $this->wsdl->getType("FLOAT"));
$this->assertEquals("xsd:double", $this->wsdl->getType("douBLE"));
$this->assertEquals("xsd:date", $this->wsdl->getType("daTe"));

$this->assertEquals("xsd:long", $this->wsdl->getType("long"));
}
Expand Down

0 comments on commit a6ae66a

Please sign in to comment.