failed tests
See original GitHub issueI co-maintain the python-jwt package in Fedora for PyJWT. The test suite is now failing in Fedora 30 and I’m not sure why. The failing tests are:
TestJWS.test_decode_no_algorithms_verify_signature_false
TestJWT.test_decode_no_algorithms_verify_false
Expected Result
Tests to pass (just like they did in Fedora 29).
Actual Result
_______________________________________ TestJWS.test_decode_no_algorithms_verify_signature_false _______________________________________
self = <tests.test_api_jws.TestJWS object at 0x7f03249037b8>, jws = <jwt.api_jws.PyJWS object at 0x7f0324903128>
def test_decode_no_algorithms_verify_signature_false(self, jws):
example_secret = 'secret'
example_jws = (
b'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.'
b'aGVsbG8gd29ybGQ.'
b'SIr03zM64awWRdPrAM_61QWsZchAtgDV3pphfHPPWkI'
)
try:
pytest.deprecated_call(
jws.decode, example_jws, key=example_secret,
> options={'verify_signature': False},
)
E Failed: DID NOT WARN. No warnings of type (<class 'DeprecationWarning'>, <class 'PendingDeprecationWarning'>) was emitted. The list of emitted warnings is: [].
tests/test_api_jws.py:295: Failed
____________________________________________ TestJWT.test_decode_no_algorithms_verify_false ____________________________________________
self = <tests.test_api_jwt.TestJWT object at 0x7f0324d987f0>, jwt = <jwt.api_jwt.PyJWT object at 0x7f0324d8c748>
payload = {'claim': 'insanity', 'exp': 1541389632, 'iss': 'jeff'}
def test_decode_no_algorithms_verify_false(self, jwt, payload):
secret = 'secret'
jwt_message = jwt.encode(payload, secret)
try:
pytest.deprecated_call(
> jwt.decode, jwt_message, secret, verify=False,
)
E Failed: DID NOT WARN. No warnings of type (<class 'DeprecationWarning'>, <class 'PendingDeprecationWarning'>) was emitted. The list of emitted warnings is: [].
tests/test_api_jwt.py:517: Failed
Full output: https://gist.github.com/carlwgeorge/563597c80e3324101d754efac99d14a1
Reproduction Steps
yum install python3-{devel,setuptools,cryptography,pytest,pytest-cov}
wget https://files.pythonhosted.org/packages/source/P/PyJWT/PyJWT-1.6.4.tar.gz
tar -xf PyJWT-1.6.4.tar.gz
cd PyJWT-1.6.4
pytest-3 -v
System Information
$ python -m jwt.help
$ python3 -m jwt.help
{
"cryptography": {
"version": "2.3"
},
"implementation": {
"name": "CPython",
"version": "3.7.1"
},
"platform": {
"release": "4.18.16-300.fc29.x86_64",
"system": "Linux"
},
"pyjwt": {
"version": "1.6.4"
}
}
Issue Analytics
- State:
- Created 5 years ago
- Comments:12 (8 by maintainers)
Top Results From Across the Web
How to run failed test cases in TestNG & Selenium
Test cases usually fail due to server and network issues, an unresponsive application or validation failure, or even due to scripting issues.
Read more >What To Do When Tests Fail? - TestProject
Tests usually fail due to server and network issues, an unresponsive application or validation failure, or scripting issues. When failures occur ...
Read more >Maven Surefire Plugin – Rerun failing tests
Rerun Failing Tests. During development, you may re-run failing tests because they are flaky. To use this feature through Maven surefire, ...
Read more >Debugging Failing Tests and Test Pipelines - GitLab
Classify the failure. After triaging failed tests, possible follow up actions are: Fixing tests; Quarantining tests; Dequarantining tests; Re-evaluating tests ...
Read more >Rerun Failed Tests - MATLAB & Simulink - MathWorks
Rerun Failed Tests. If a test failure is caused by incorrect or incomplete code, it is useful to rerun failed tests quickly and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
It’s said to see you’re viewing pinning the pytest version as a solution to this.
https://github.com/jpadilla/pyjwt/releases/tag/1.7.1