/** * @dataProvider getClients */ public function testSimpleMulticall(ClientInterface $client) { $this->expected = $expected = array(array('Idaho'), array('Michigan'), array('New York'), array('Tennessee')); $result = $client->multicall()->addCall('examples.getStateName', array(12))->addCall('examples.getStateName', array(22))->addCall('examples.getStateName', array(32))->addCall('examples.getStateName', array(42))->onSuccess(array($this, 'handler'))->execute(); $this->assertSame($expected, $result); $this->assertSame(4, $this->handlerInvoked); }