コード例 #1
0
ファイル: tests.php プロジェクト: khk0613/YHK
 public function testExceptionConstructorWithErrorCode()
 {
     $code = 404;
     $e = new FacebookApiException(array('error_code' => $code));
     $this->assertEquals($code, $e->getCode());
 }
コード例 #2
0
ファイル: tests.php プロジェクト: newshorts/Examples
 public function testExceptionConstructorWithInvalidErrorCode()
 {
     $e = new FacebookApiException(array('error_code' => 'not an int'));
     $this->assertEquals(0, $e->getCode());
 }