Skip to content

Commit

Permalink
refactor(utils): miscellaneous
Browse files Browse the repository at this point in the history
* use relocated utils and remove pymake dependency
* move n-point cross-section functions from modflow6
  • Loading branch information
wpbonelli committed Dec 22, 2022
1 parent bd51afa commit cbf727f
Show file tree
Hide file tree
Showing 17 changed files with 385 additions and 210 deletions.
1 change: 0 additions & 1 deletion .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ jobs:
shell: bash -l {0}
run: |
pip install --upgrade pip
pip install https://github.com/modflowpy/pymake/zipball/master
pip install xmipy
pip install .
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,6 @@ jobs:
if: runner.os == 'Windows'
run: |
pip install --upgrade pip
pip install https://github.com/modflowpy/pymake/zipball/master
pip install xmipy
pip install .
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ jobs:
shell: bash -l {0}
run: |
pip install --upgrade pip
pip install https://github.com/modflowpy/pymake/zipball/master
pip install xmipy
pip install .
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/regression.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ jobs:
shell: bash -l {0}
run: |
pip install --upgrade pip
pip install https://github.com/modflowpy/pymake/zipball/master
pip install xmipy
pip install .
Expand Down
8 changes: 5 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,12 @@ Before you submit your Pull Request (PR) consider the following guidelines:

```shell
cd autotest
pytest -v ci_prepare.py
pytest -v
pytest -v -n auto
```
Note: the FloPy test suite requires the [pytest](https://pypi.org/project/pytest/) and [pymake](https://github.com/modflowpy/pymake) python packages. All the FloPy dependencies must also be installed for the tests to pass.

**Note**: the FloPy test suite requires the [pytest](https://pypi.org/project/pytest/) and [modflow-devtools](https://github.com/MODFLOW-USGS/modflow-devtools) python packages. Be sure to install all optional dependencies as described in the [developer docs](DEVELOPER.md), as tests will be skipped if optional dependencies are not found.

**Note:** you will either need to exclude notebooks when checking in your changeset or restore them after running the full test suite, to avoid including large volumes of execution metadata with your PR.

7. Commit your changes using a descriptive commit message that follows our
[commit message conventions](#commit). Adherence to these conventions
Expand Down
8 changes: 3 additions & 5 deletions autotest/regression/test_lgr.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,14 @@
from modflow_devtools.markers import requires_exe, requires_pkg

import flopy
from flopy.utils.compare import compare_heads


@flaky
@requires_exe("mflgr")
@requires_pkg("pymake")
@pytest.mark.regression
def test_simplelgr(function_tmpdir, example_data_path):
"""Test load and write of distributed MODFLOW-LGR example problem."""
import pymake

mflgr_v2_ex3_path = example_data_path / "mflgr_v2" / "ex3"

ws = function_tmpdir / mflgr_v2_ex3_path.stem
Expand Down Expand Up @@ -66,12 +64,12 @@ def test_simplelgr(function_tmpdir, example_data_path):
print("compare parent results")
pth0 = join(ws, "ex3_parent.nam")
pth1 = join(model_ws2, "ex3_parent.nam")
success = pymake.compare_heads(pth0, pth1)
success = compare_heads(pth0, pth1)
assert success, "parent heads do not match"

# compare child results
print("compare child results")
pth0 = join(ws, "ex3_child.nam")
pth1 = join(model_ws2, "ex3_child.nam")
success = pymake.compare_heads(pth0, pth1)
success = compare_heads(pth0, pth1)
assert success, "child heads do not match"
Loading

0 comments on commit cbf727f

Please sign in to comment.