From dc1cdd2b761e3f521269d44ead39d1a5d7488ff2 Mon Sep 17 00:00:00 2001 From: versat Date: Fri, 20 Sep 2019 13:39:38 +0200 Subject: [PATCH] addons/test/test-*.py: Improve documentation about running the tests --- addons/test/test-cert.py | 7 +++++++ addons/test/test-misra.py | 7 +++++++ addons/test/test-y2038.py | 7 +++++++ 3 files changed, 21 insertions(+) diff --git a/addons/test/test-cert.py b/addons/test/test-cert.py index b7694fd60..8475e8b79 100644 --- a/addons/test/test-cert.py +++ b/addons/test/test-cert.py @@ -1,4 +1,11 @@ +# Running the test with Python 2: +# Be sure to install pytest version 4.6.4 (newer should also work) +# Command in cppcheck directory: # python -m pytest addons/test/test-cert.py +# +# Running the test with Python 3: +# Command in cppcheck directory: +# PYTHONPATH=./addons python3 -m pytest addons/test/test-cert.py import sys import pytest diff --git a/addons/test/test-misra.py b/addons/test/test-misra.py index 09cf3385c..a6b242cb3 100644 --- a/addons/test/test-misra.py +++ b/addons/test/test-misra.py @@ -1,4 +1,11 @@ +# Running the test with Python 2: +# Be sure to install pytest version 4.6.4 (newer should also work) +# Command in cppcheck directory: # python -m pytest addons/test/test-misra.py +# +# Running the test with Python 3: +# Command in cppcheck directory: +# PYTHONPATH=./addons python3 -m pytest addons/test/test-misra.py import pytest import re diff --git a/addons/test/test-y2038.py b/addons/test/test-y2038.py index ad7eae6ee..caf009bbf 100644 --- a/addons/test/test-y2038.py +++ b/addons/test/test-y2038.py @@ -1,4 +1,11 @@ +# Running the test with Python 2: +# Be sure to install pytest version 4.6.4 (newer should also work) +# Command in cppcheck directory: # python -m pytest addons/test/test-y2038.py +# +# Running the test with Python 3: +# Command in cppcheck directory: +# PYTHONPATH=./addons python3 -m pytest addons/test/test-y2038.py import sys import pytest