Skip to content

Commit

Permalink
add test for e5378e9
Browse files Browse the repository at this point in the history
ensuring the user_id is returned by the verify_auth_code default method

bump VERSION and Changes for CPAN release
  • Loading branch information
leejo committed Apr 27, 2019
1 parent 1078098 commit dc3030d
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Changes
@@ -1,6 +1,6 @@
Revision history for Net-OAuth2-AuthorizationServer

0.21 2019-04-26
0.22 2019-04-27
- Add support for JWEs as well as JWTs (GH #24)
- Fix make sure user_id is returned in AuthorizationCodeGrant defaults

Expand Down
2 changes: 1 addition & 1 deletion README.md
Expand Up @@ -11,7 +11,7 @@ Authorization Server

# VERSION

0.21
0.22

# SYNOPSIS

Expand Down
4 changes: 2 additions & 2 deletions lib/Net/OAuth2/AuthorizationServer.pm
Expand Up @@ -11,7 +11,7 @@ Authorization Server
=head1 VERSION
0.21
0.22
=head1 SYNOPSIS
Expand Down Expand Up @@ -45,7 +45,7 @@ use Net::OAuth2::AuthorizationServer::ImplicitGrant;
use Net::OAuth2::AuthorizationServer::PasswordGrant;
use Net::OAuth2::AuthorizationServer::ClientCredentialsGrant;

our $VERSION = '0.21';
our $VERSION = '0.22';

=head1 GRANT TYPES
Expand Down
Expand Up @@ -31,7 +31,7 @@ foreach my $with_callbacks ( 0,1 ) {
'Net::OAuth2::AuthorizationServer::AuthorizationCodeGrant'
);

authorizationcodegrant_tests::run_tests( $Grant );
authorizationcodegrant_tests::run_tests( $Grant,{ no_jwt => 1 } );
}

done_testing();
Expand Up @@ -116,10 +116,11 @@ sub run_tests {
redirect_uri => 'https://come/back',
);

my ( $client,$vac_error,$scopes ) = $Grant->verify_auth_code( %valid_auth_code );
my ( $client,$vac_error,$scopes,$user_id ) = $Grant->verify_auth_code( %valid_auth_code );

ok( $client,'->verify_auth_code, correct args' );
ok( ! $vac_error,'has no error' );
is( $user_id,$args->{no_jwt} ? undef : 1,'user_id' );
cmp_deeply( $scopes,[ qw/ eat sleep / ],'has scopes' );

foreach my $t (
Expand Down

0 comments on commit dc3030d

Please sign in to comment.