コード例 #1
0
ファイル: MockClient.php プロジェクト: JJVV27/FantasyDataAPI
 /**
  * @param array $pOptions
  *
  * @return \GuzzleHttp\Client
  */
 protected function CreateHttpClient($pOptions = array())
 {
     /**
      * My gut says there must be a much better way of doing this, if you run across a
      * better way, please issue a pull request or drop me a message. @oakensoul
      */
     $mockAdapter = new MockAdapter(function (TransactionInterface $trans) {
         return ResponseFactory::GetResponse($trans);
     });
     return parent::CreateHttpClient(['adapter' => $mockAdapter]);
 }