Skip to content
Myr

test ssl version check functions as expected in python 2.6

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Nate Prewitt · committed by Nate Prewitt · parent f6e07bb · Browse files · 1 file+21 added−0 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+21 added−0 removed

  • tests:+21 added−0 removed

1 file+21 added−0 removed

added:tests/test_help.py+21 added
1# -*- encoding: utf-823import sys45import pytest67from requests.help import info8910@pytest.mark.skipif(sys.version_info[:2] != (2,6), reason="Only run on Python 2.6")11def test_system_ssl_py26():12 """OPENSSL_VERSION_NUMBER isn't provided in Python 2.6, verify we don't13 blow up in this case.14 """15 assert info()['system_ssl'] == {'version': ''}161718@pytest.mark.skipif(sys.version_info < (2,7), reason="Only run on Python 2.7+")19def test_system_ssl():20 """Verify we're actually setting system_ssl when it should be available."""21 assert info()['system_ssl']['version'] != ''