[ci][python] Implement test selection
Python tests are excluded in the normal pipeline (they don't require the build
job and can run therefore run earlier). There is a separate test
job for the Python tests. What's currently missing for these tests is a select
mechanism like for the C++ tests.
Since stuff in the Python code is just-in-time compiled it's not possible to know what header will be compiled without running the actual test.
I suggest to apply a heuristic and only run Python tests if something changed in a file in dumux/python
or dumux/dumux/python
. If that is the case we run all Python tests. That way the Python tests are only run when a merge request changes something in the Python bindings. Unfortunately it can happen then that a change in the C++ headers breaks the bindings. But this hopefully doesn't happen since the interfaces used by the binding code have some backwards-compatibility assurance. If not we will get the failure in the next nightly build.
Python test take quite long because they build&test so it would be good to have this selection.