Files
wehub-resource-sync 593b94c120
pytest / Unit Tests (push) Has been cancelled
pytest / Integration (integration_tests_a) (push) Has been cancelled
pytest / Integration (integration_tests_b) (push) Has been cancelled
pytest / Integration (integration_tests_c) (push) Has been cancelled
pytest / Integration (integration_tests_d) (push) Has been cancelled
pytest / Integration (integration_tests_e) (push) Has been cancelled
pytest / Integration (integration_tests_f) (push) Has been cancelled
pytest / Integration (integration_tests_g) (push) Has been cancelled
pytest / Integration (integration_tests_h) (push) Has been cancelled
pytest / Integration (integration_tests_i) (push) Has been cancelled
pytest / Integration (integration_tests_j) (push) Has been cancelled
pytest / Distributed (distributed_a) (push) Has been cancelled
pytest / Distributed (distributed_b) (push) Has been cancelled
pytest / Distributed (distributed_c) (push) Has been cancelled
pytest / Distributed (distributed_d) (push) Has been cancelled
pytest / Distributed (distributed_e) (push) Has been cancelled
pytest / Distributed (distributed_f) (push) Has been cancelled
pytest / Minimal Install (push) Has been cancelled
pytest / Event File (push) Has been cancelled
pytest (slow) / py-slow (push) Has been cancelled
Publish JSON Schema / publish-schema (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 12:49:20 +08:00

35 lines
972 B
Python

import importlib.util
import logging
import os
import subprocess
import sys
import pytest
logger = logging.getLogger(__name__)
logger.setLevel(logging.INFO)
logging.getLogger("ludwig").setLevel(logging.INFO)
TEST_SCRIPT = os.path.join(os.path.dirname(__file__), "scripts", "run_train_comet.py")
@pytest.mark.skipif(
not importlib.util.find_spec("pkg_resources"),
reason="comet_ml requires pkg_resources (removed in setuptools 82+)",
)
@pytest.mark.skipif(
not importlib.util.find_spec("imp"),
reason="comet_ml requires imp module (removed in Python 3.12)",
)
def test_contrib_experiment(csv_filename):
cmdline = [sys.executable, TEST_SCRIPT, "--csv-filename", csv_filename]
exit_code = subprocess.call(" ".join(cmdline), shell=True, env=os.environ.copy())
assert exit_code == 0
if __name__ == "__main__":
"""To run tests individually, run:
```python -m pytest tests/integration_tests/test_contrib_comet.py::test_name```
"""