| Total Complexity | 1 |
| Total Lines | 20 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 5 | class FilesystemTest extends BaseTest |
||
| 6 | { |
||
| 7 | |||
| 8 | /** |
||
| 9 | * Test that a referenced Xsd file is found when the base-path contains " " (space-character). |
||
| 10 | * |
||
| 11 | * Covers the issue described in {@link https://github.com/goetas/xsd-reader/pull/10 PR #10}. |
||
| 12 | */ |
||
| 13 | public function testReferencedOnFileSystem_1() |
||
| 14 | { |
||
| 15 | /* |
||
| 16 | * Using vfsStream seems ideal, but currently seems to have an issue with directorypaths with a space in |
||
| 17 | * combination with DOMDocument::load(). For now use actual filesystem to create the testcase. |
||
| 18 | */ |
||
| 19 | $schemaXsd = __DIR__ . DIRECTORY_SEPARATOR . 'foo bar' . DIRECTORY_SEPARATOR . 'schema.xsd'; |
||
| 20 | |||
| 21 | $schema = $this->reader->readFile($schemaXsd); |
||
| 22 | |||
| 23 | $this->assertCount(1, $schema->getTypes()); |
||
| 24 | $this->assertInstanceOf('GoetasWebservices\XML\XSDReader\Schema\Type\ComplexType', $schema->findType('myType', 'http://www.example.com')); |
||
| 25 | } |
||
| 28 |