Skip to content

Commit 21ae4f8

Browse files
committed
Add another note
1 parent 73f2d3f commit 21ae4f8

1 file changed

Lines changed: 7 additions & 4 deletions

File tree

tests/conftest.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,15 @@
3333

3434

3535
def pytest_collection_modifyitems(config, items):
36-
# Handle tests marked with tensorrtllm
36+
"""
37+
This function is called to modify the list of tests to run.
38+
It is used to skip tests that are not supported on all environments.
39+
"""
40+
41+
# Tests marked with tensorrtllm requires specific environment with tensorrtllm
42+
# installed. Hence, we skip them if the user did not explicitly ask for them.
3743
if config.getoption("-m") and "tensorrtllm" in config.getoption("-m"):
38-
# User explicitly asked for tensorrtllm tests, do nothing
3944
return
40-
41-
# Otherwise, skip all tests marked with tensorrtllm
4245
skip_tensorrtllm = pytest.mark.skip(reason="need -m tensorrtllm to run")
4346
for item in items:
4447
if "tensorrtllm" in item.keywords:

0 commit comments

Comments
 (0)