Skip to content

Commit

Permalink
πŸ› GacebookConnect not handle exception correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
edbizarro committed Apr 17, 2019
1 parent 0919131 commit 252abd6
Show file tree
Hide file tree
Showing 8 changed files with 6 additions and 9 deletions.
Empty file modified src/Bi/Exceptions/AdobeConnectException.php
100755 β†’ 100644
Empty file.
4 changes: 3 additions & 1 deletion src/Bi/Exceptions/FacebookConnectException.php
100755 β†’ 100644
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace Bi\Connect\Exceptions;

class FacebookConnectException extends \Exception
use Exception;

class FacebookConnectException extends Exception
{
}
3 changes: 0 additions & 3 deletions src/Bi/Exceptions/GoogleAuthException.php
100755 β†’ 100644
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@

namespace Bi\Connect\Exceptions;

/**
* Class GoogleAuthException.
*/
class GoogleAuthException extends \Exception
{
}
Empty file modified src/Bi/Exceptions/GoogleConnectException.php
100755 β†’ 100644
Empty file.
Empty file modified src/Bi/Exceptions/GoogleCredentialsException.php
100755 β†’ 100644
Empty file.
Empty file modified src/Bi/Exceptions/IntervalException.php
100755 β†’ 100644
Empty file.
Empty file modified src/Bi/Exceptions/TwitterConnectException.php
100755 β†’ 100644
Empty file.
8 changes: 3 additions & 5 deletions tests/FacebookAds/FacebookAdsTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
namespace Edbizarro\BiConnect\Tests\FacebookAds;

use Bi\Connect\Base\Oauth2Connect;
use Bi\Connect\Exceptions\FacebookConnectException;
use Bi\Connect\Exceptions\FBConnectException;
use Bi\Connect\Facebook\FacebookConnect;
use PHPUnit\Framework\TestCase;

Expand Down Expand Up @@ -33,18 +33,16 @@ public function it_can_instantiate(): void
/** @test */
public function it_cant_get_login_url_without_scope(): void
{
$this->expectException(FacebookConnectException::class);

$this->fbConnect->getLoginUrl();
$this->expectException(FBConnectException::class);
}

/** @test */
public function it_cant_get_login_url_without_redirect(): void
{
$this->expectException(FacebookConnectException::class);

$this->fbConnect->addScope('analytics');
$this->fbConnect->getLoginUrl();
$this->expectException(FBConnectException::class);
}

/** @test */
Expand Down

0 comments on commit 252abd6

Please sign in to comment.