From f0dd92a4474190c0a91cf45f4cfa559099a9f85a Mon Sep 17 00:00:00 2001 From: ronilpatil Date: Tue, 26 Mar 2024 14:03:13 +0530 Subject: [PATCH] minor update in testing env --- tests/test_main.py | 3 +++ tox.ini | 14 ++++++++++++-- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/tests/test_main.py b/tests/test_main.py index d5075fd..2957930 100644 --- a/tests/test_main.py +++ b/tests/test_main.py @@ -32,6 +32,9 @@ def test_load_data(load_dataset) : else : pytest.fail('Unable to fetch data from remote server') + # ---- OR ---- + # assert isinstance(load_dataset, pd.DataFrame), "Failure Message" # it will raise assertion error + # test feature generation functionality # 'request' is a fixture that provides information about the currently executing test. # It allows us to access various attributes and methods to get information about the test diff --git a/tox.ini b/tox.ini index ff4a7c1..83219d3 100644 --- a/tox.ini +++ b/tox.ini @@ -1,7 +1,17 @@ [tox] # global settings -envlist = py39 # define the list of environment to test against +envlist = py39, py312 # define the list of environment to test against skipsdist = True # skip creating package [testenv] deps = -rrequirements-tox.txt # dependency -commands = pytest tests/ # testcases +; commands = pytest tests/ --verbose --disable-warnings # testcases + +; we can also execute differet testing files with diff python versions +[testenv:py39] +basepython = python3.9 +commands = pytest tests/ --verbose --disable-warnings + +[testenv:py312] +basepython = python3.12 +commands = pytest tests/ --verbose --disable-warnings +