-
-
Notifications
You must be signed in to change notification settings - Fork 176
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update loader in CodeGeneratorEngineFactory
The code update removes the dependency on Psr18ClientDiscovery and Psr18Loader and replaces it with StreamWrapperLoader in the CodeGeneratorEngineFactory. Additionally, a corresponding test for this change has been created in CodeGeneratorEngineFactoryTest to verify that the engine can be correctly loaded from the filesystem. Fixes #510
- Loading branch information
1 parent
7b7cd0e
commit 29be0c6
Showing
2 changed files
with
19 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
test/Phpro/SoapClient/Soap/CodeGeneratorEngineFactoryTest.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?php | ||
|
||
namespace Phpro\SoapClient\Soap; | ||
|
||
use PHPUnit\Framework\TestCase; | ||
use Soap\Engine\Engine; | ||
use Soap\Engine\Metadata\Metadata; | ||
|
||
class CodeGeneratorEngineFactoryTest extends TestCase | ||
{ | ||
public function test_it_loads_from_filesystem(): void | ||
{ | ||
$engine = CodeGeneratorEngineFactory::create(__DIR__ . '/../../../fixtures/wsdl/functional/calculator.wsdl'); | ||
$this->assertInstanceOf(Engine::class, $engine); | ||
self::assertInstanceOf(Metadata::class, $engine->getMetadata()); | ||
} | ||
} |