* @license MIT * * @group Coverage */ class SoapTest extends PHPUnit_Framework_TestCase { /** * {@inheritDoc} * * @covers \ProxyManager\Factory\RemoteObject\Adapter\Soap::__construct * @covers \ProxyManager\Factory\RemoteObject\Adapter\Soap::getServiceName */ public function testCanBuildAdapterWithSoapRpcClient() { $client = $this ->getMockBuilder('Zend\Server\Client') ->setMethods(array('call')) ->getMock(); $adapter = new Soap($client); $client ->expects($this->once()) ->method('call') ->with('bar', array('tab' => 'taz')) ->will($this->returnValue('baz')); $this->assertSame('baz', $adapter->call('foo', 'bar', array('tab' => 'taz'))); } }