Skip to content

Fix "Fast tests (core only)" CI: skip tests requiring optional Tasmanian/pyomo dependencies - #2

Merged
adowling2 merged 2 commits into
copilot/fix-fast-tests-core-only-python-3-9from
copilot/continue-fix-fast-tests-job-14
Aug 17, 2026
Merged

Fix "Fast tests (core only)" CI: skip tests requiring optional Tasmanian/pyomo dependencies#2
adowling2 merged 2 commits into
copilot/fix-fast-tests-core-only-python-3-9from
copilot/continue-fix-fast-tests-job-14

Conversation

Copilot AI commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

The fast CI job (.[dev] install only) was failing with ModuleNotFoundError on 4 tests that exercise optional-dependency code paths — Tasmanian (sparse-grid acquisition) and pyomo (Müller case studies CS2/CS3) — neither of which is installed in that job.

Changes

  • tests/unit/test_acquisition.py — added pytest.importorskip("Tasmanian") to the two sparse-grid EI tests that invoke the SPARSE_GRID acquisition path:

    • test_ei_sparse_is_deterministic_and_nonnegative
    • test_ei_sparse_ldl_fallback_for_non_positive_definite_covariance
  • tests/unit/test_calibration_problem.py — added pytest.importorskip("pyomo") inside the parametrized test_get_case_study_returns_valid_problem for cs in (2, 3), which construct CSMuller and call into __solve_pyomo_Muller_min at init time.

# test_acquisition.py
def test_ei_sparse_is_deterministic_and_nonnegative():
    pytest.importorskip("Tasmanian")
    ...

# test_calibration_problem.py
def test_get_case_study_returns_valid_problem(cs):
    if cs in (2, 3):
        pytest.importorskip("pyomo")
    ...

Both modules are already lazy-imported in production code; only the test side was missing the guard.

Co-authored-by: adowling2 <13946870+adowling2@users.noreply.github.com>
Co-authored-by: adowling2 <13946870+adowling2@users.noreply.github.com>
Copilot AI requested a review from adowling2 August 17, 2026 13:13
@adowling2
adowling2 merged commit 8396982 into main Aug 17, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants