Skip to content

Refactor Python tests to make consistent use of pytest ECFLOW-2110#381

Open
marcosbento wants to merge 15 commits into
developfrom
task/use_pytest
Open

Refactor Python tests to make consistent use of pytest ECFLOW-2110#381
marcosbento wants to merge 15 commits into
developfrom
task/use_pytest

Conversation

@marcosbento

@marcosbento marcosbento commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

Description

As per PR title.

Contributor Declaration

By opening this pull request, I affirm the following:

  • All authors agree to the Contributor License Agreement.
  • The code follows the project's coding standards.
  • I have performed self-review and added comments where needed.
  • I have added or updated tests to verify that my changes are effective and functional.
  • I have run all existing tests and confirmed they pass.

🌦️ >> Documentation << 🌦️
https://sites.ecmwf.int/docs/dev-section/ecflow/pull-requests/PR-381

@marcosbento marcosbento changed the title Refactor Python tests to use pytest Refactor Python tests to make consistent use of pytest ECFLOW-2110 Jul 9, 2026
@marcosbento
marcosbento force-pushed the task/use_pytest branch 2 times, most recently from ad40acd to 11b0136 Compare July 10, 2026 08:58
@codecov-commenter

codecov-commenter commented Jul 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 52.08%. Comparing base (e38ed88) to head (28ab0be).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop     #381   +/-   ##
========================================
  Coverage    52.08%   52.08%           
========================================
  Files         1247     1247           
  Lines       101710   101710           
  Branches     15136    15136           
========================================
+ Hits         52971    52975    +4     
+ Misses       48739    48735    -4     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@marcosbento
marcosbento force-pushed the task/use_pytest branch 5 times, most recently from 8b169e2 to c057178 Compare July 16, 2026 18:28
At this point, there is a single entry point that is pytest collected,
but then the "tests" are executed by sequentially calling the test
functions as before.

Re ECFLOW-2110
This class simply delegates to the preexisting _test_*.

Re ECFLOW-2110
This effectively inlines the _test_* functions into the test, and thus
concludes the migration of the integration tests to pytest.

Re ECFLOW-2110
This is a small improvement, detected during code review.

Re ECFLOW-2110
This is a small improvement, detected during code review.

Re ECFLOW-2110
This covers a small set of improvements, detected during code review.

Re ECFLOW-2110
On some HPC toolchains, a third-party Python package imported before
ecflow (for example numpy) resolves and loads the platform default
libstdc++ first. Since ELF soname resolution is process-wide and
first-one-wins, this can leave ecflow.so unable to satisfy the GLIBCXX
symbol version it was actually built against, when the build toolchain
differs from the platform default.

Add ECFLOW_PYEXT_TEST_LD_LIBRARY_PATH, a configure-time cache
variable that prepends a given runtime library directory to
LD_LIBRARY_PATH for the py3_u_* and py3_s_* tests, so the correct
libstdc++.so.6 is resolved regardless of which component asks for it
first. Left empty by default, leaving unaffected platforms untouched.

Wire the new flag into the gnu-15.2.0 and gnu-14.2.0 HPC CI jobs in
.github/ci-hpc-config.yml, pointing at each toolchain's libstdc++
directory, so the affected python tests actually pass in CI.
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