1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37
|
Description: remove 'pending' from tests passing with a newer version of openssl 3
the pending tag was added due to a regression in earlier version with empty keys
Forwarded: not needed
Author: Cédric Boutillier <boutil@debian.org>
Last-Update: 2022-11-30
--- a/spec/jwt/jwt_spec.rb
+++ b/spec/jwt/jwt_spec.rb
@@ -595,7 +595,7 @@ RSpec.describe JWT do
context 'when hmac algorithm is used without secret key' do
it 'encodes payload' do
- pending 'Different behaviour on OpenSSL 3.0 (https://github.com/openssl/openssl/issues/13089)' if JWT.openssl_3_hmac_empty_key_regression?
+ #pending 'Different behaviour on OpenSSL 3.0 (https://github.com/openssl/openssl/issues/13089)' if JWT.openssl_3_hmac_empty_key_regression?
payload = { a: 1, b: 'b' }
token = JWT.encode(payload, '', 'HS256')
@@ -726,7 +726,7 @@ RSpec.describe JWT do
describe 'when token signed with nil and decoded with nil' do
let(:no_key_token) { JWT.encode(payload, nil, 'HS512') }
it 'raises JWT::DecodeError' do
- pending 'Different behaviour on OpenSSL 3.0 (https://github.com/openssl/openssl/issues/13089)' if JWT.openssl_3_hmac_empty_key_regression?
+ #pending 'Different behaviour on OpenSSL 3.0 (https://github.com/openssl/openssl/issues/13089)' if JWT.openssl_3_hmac_empty_key_regression?
expect { JWT.decode(no_key_token, nil, true, algorithms: 'HS512') }.to raise_error(JWT::DecodeError, 'No verification key available')
end
end
--- a/spec/integration/readme_examples_spec.rb
+++ b/spec/integration/readme_examples_spec.rb
@@ -29,7 +29,7 @@ RSpec.describe 'README.md code test' do
end
it 'decodes with HMAC algorithm without secret key' do
- pending 'Different behaviour on OpenSSL 3.0 (https://github.com/openssl/openssl/issues/13089)' if JWT.openssl_3_hmac_empty_key_regression?
+ #pending 'Different behaviour on OpenSSL 3.0 (https://github.com/openssl/openssl/issues/13089)' if JWT.openssl_3_hmac_empty_key_regression?
token = JWT.encode payload, nil, 'HS256'
decoded_token = JWT.decode token, nil, false
|