Skip to content

Commit

Permalink
Merge pull request #18 from ankurk91/patch/passport-8
Browse files Browse the repository at this point in the history
Passport v8 support
  • Loading branch information
Ilya Sakovich committed Nov 4, 2019
2 parents 44d8bae + a06ece7 commit eeecb0f
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .gitignore
@@ -1,2 +1,3 @@
vendor
composer.lock
composer.lock
.phpunit.result.cache
2 changes: 1 addition & 1 deletion composer.json
Expand Up @@ -12,7 +12,7 @@
],
"require": {
"php": ">=7.1",
"laravel/passport": "^6.0|^7.0"
"laravel/passport": "^6.0|^7.0|^8.0"
},
"require-dev": {
"mockery/mockery": "^1.1",
Expand Down
2 changes: 2 additions & 0 deletions tests/SocialGrantTest.php
Expand Up @@ -2,6 +2,7 @@

namespace Coderello\SocialGrant\Tests;

use League\OAuth2\Server\CryptKey;
use Zend\Diactoros\ServerRequest;
use Coderello\SocialGrant\Tests\Stubs\User;
use League\OAuth2\Server\Exception\OAuthServerException;
Expand Down Expand Up @@ -62,6 +63,7 @@ public function test_respond_to_request()
$grant->setAccessTokenRepository($accessTokenRepositoryMock);
$grant->setScopeRepository($scopeRepositoryMock);
$grant->setDefaultScope(self::DEFAULT_SCOPE);
$grant->setPrivateKey(new CryptKey('file://'.__DIR__.'/Stubs/private.key', null, false));

$serverRequest = new ServerRequest();
$serverRequest = $serverRequest->withParsedBody(
Expand Down
15 changes: 15 additions & 0 deletions tests/Stubs/private.key
@@ -0,0 +1,15 @@
-----BEGIN RSA PRIVATE KEY-----
MIICXgIBAAKBgQDOBcFjGUlo3BJ9zjwQLgAHn6Oy5Si0uB7MublTiPob8rWTiCE4
weAFqzPoAB07vB0t0f8c1R8rmwHMD5ljWPBgJ8FewtwAUzprOBcau6DWukd/TKxX
WeVLAl/NZxijI+jR5QDBYLNBtj1G4LBVHMmINd3ryCycbf9ac3rcC8zhrQIDAQAB
AoGADfOJ0wIlXHp6rhZHLvlOezWuSjEGfqZxP3/cMvH1rerTrPfs+AD5AKlFTJKl
aCQm/bFYy0ULZVKL3pu30Wh2bo1nh/wLuLSI9Nz3O8jqAP3z0i07SoRoQmb8fRnn
dwoDFqnk3uGqcOenheSqheIgl9vdW/3avhD6nkMKZGxPYwECQQDoSj/xHogEzMqB
1Z2E5H/exeE9GQ7+dGITRR2MSgo9WvcKdRhGaQ44dsnTmqiZWAfqAPJjTQIIA/Cn
YRRTeBbNAkEA4w0iEvCIygGQOAnWuvVzlh+pxIB+BTeGkbiBG7nkYYc9b6B/Tw1B
GWGRddBr/FIfPvy1X2ip/TBpH+9bHnE2YQJBAIbZw/EYhmIy+UUSW9WwSUNsoOu1
Rm0V53HEZ/jvaq5fxpa9j5AgoO7KlzROzp3m6wE/93cKV6mLkAO7ae9jAekCQQCf
B6DZIS6+RrAMACAt3SOzf8P6BYG/B7Ayusd7cw2ang4S9JiW9xKkw2kN2wj3t1F5
XalwBTAjTdgj7ROmU+ehAkEAkOyXKONGBoVfaixRHgBP6jIBSSPbB2Aosi0QAURX
6GOY7wOS1pCSntTOBQxV7wVjqFwYAR10MSxFSNfpJ7RkzA==
-----END RSA PRIVATE KEY-----

0 comments on commit eeecb0f

Please sign in to comment.