|
1 | | -name: Build and test UW3 |
| 1 | +name: test_uw3 |
2 | 2 |
|
3 | 3 | # We should trigger this from an upload event. Note that pdoc requires us to import the |
4 | 4 | # built code, so this is a building test as well as documentation deployment |
|
15 | 15 | workflow_dispatch: |
16 | 16 |
|
17 | 17 | jobs: |
18 | | - deploy: |
19 | | - runs-on: ubuntu-20.04 |
| 18 | + test: |
| 19 | + runs-on: ubuntu-latest |
20 | 20 | steps: |
21 | | - - uses: actions/checkout@v3 |
| 21 | + - uses: actions/checkout@v4 |
22 | 22 |
|
23 | 23 | - name: Install Conda environment with Micromamba |
24 | | - uses: mamba-org/setup-micromamba@v1 |
| 24 | + uses: mamba-org/setup-micromamba@v2 |
25 | 25 | with: |
26 | | - environment-file: ./.github/workflows/envs/build_uw_test.yml |
| 26 | + environment-file: ./environment.yml |
27 | 27 | cache-downloads: true |
28 | 28 | cache-environment: true |
29 | 29 |
|
30 | | - # the following may be needed if conda-forge is out of date |
31 | | - # - name: Add compatible petsc4py |
32 | | - # shell: bash -l {0} |
33 | | - # run: | |
34 | | - # export PETSC_DIR="/home/runner/micromamba-root/envs/uw3_test" |
35 | | - # pip3 install petsc4py==3.18 --upgrade |
36 | | - |
37 | | - # gmsh is such a pig to install properly |
38 | | - - name: Add gmsh package |
39 | | - shell: bash -l {0} |
40 | | - run: | |
41 | | - pip install gmsh |
42 | | -
|
43 | 30 | - name: Build UW3 |
44 | 31 | shell: bash -l {0} |
45 | 32 | run: | |
46 | 33 | export PETSC_DIR="/home/runner/micromamba/envs/uw3_test/lib" |
47 | 34 | VERSION=`python3 setup.py --version` |
48 | 35 | echo "UW - version " ${VERSION} |
49 | 36 |
|
50 | | - python3 setup.py develop |
51 | | - pip3 install -e . |
| 37 | + ## TODO. Use compile.sh once it is in development |
| 38 | + pip install -e . --no-build-isolation |
52 | 39 |
|
53 | | - # Test - split into short, low memory tests 0???_* |
54 | | - # and longer, solver-based tests 1???_* |
55 | | - |
56 | | - - name: Run pytest |
| 40 | + - name: Run tests |
57 | 41 | shell: bash -l {0} |
58 | 42 | run: | |
59 | | - pytest tests/test_00??*py |
60 | | - pytest tests/test_0[1-9]??*py |
61 | | -
|
62 | | - # Poisson solver tests |
63 | | - pytest tests/test_100[0-9]*py |
64 | | -
|
65 | | - # Stokes solver tests |
66 | | - pytest tests/test_1010*py |
67 | | - pytest tests/test_1011*py |
68 | | - pytest tests/test_1050*py |
69 | | -
|
70 | | - # Advection/Diffusion solvers |
71 | | - pytest tests/test_1100*py |
72 | | - pytest tests/test_1110*py |
| 43 | + ./test.sh |
0 commit comments