Skip to content

Latest commit

 

History

History
39 lines (30 loc) · 832 Bytes

README.md

File metadata and controls

39 lines (30 loc) · 832 Bytes

Multiple-Version compatibility Check to Python Code (Tox example)

The Python project aims to test the compatibility of code with multiple Python versions using the tools tox, pyenv, and pytest.

Use case

Test the Python script for compatibility with versions 3.7, 3.8, 3.9, 3.10, and 3.11.

How to

  1. install tox in the global environment
pip install tox
  1. install pytest in the global environment
pip install pytest
  1. install python versions
pyenv install 3.7
pyenv install 3.8
pyenv install 3.9
pyenv install 3.10
pyenv install 3.11
  1. run tox
tox run

Result

Tox displays the issues in each file for each Python version: report and then provides the most compatible Python versions at the end of the report. report