Exemplo n.º 1
0
 public function it_get_account_funds(ParamFactory $paramFactory, Param $param, BetfairClientInterface $client, AdapterInterface $adapterInterface)
 {
     $paramFactory->create()->shouldBeCalled()->willReturn($param);
     $client->apiNgRequest("getAccountFunds", $param, "account")->shouldBeCalled()->willReturn("{account}");
     $adapterInterface->adaptResponse("{account}")->willReturn(array("account"));
     $this->getAccountFunds()->shouldReturn(array("account"));
 }
 public function it_get_results(ParamFactory $paramFactory, ParamInterface $param, BetfairClientInterface $betfairClient, AdapterInterface $adapter)
 {
     $paramFactory->create()->shouldBeCalled()->willReturn($param);
     $param->setMarketFilter($this->marketFilter)->shouldBeCalled();
     $param->setLocale($this->locale)->shouldBeCalled();
     $betfairClient->apiNgRequest("default", $param, "betting")->shouldBeCalled()->willReturn("response");
     $adapter->adaptResponse("response")->shouldBeCalled();
     $this->getResults();
 }