-
-
Notifications
You must be signed in to change notification settings - Fork 19
101 lines (89 loc) · 2.99 KB
/
Copy pathtest-unit.yml
File metadata and controls
101 lines (89 loc) · 2.99 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
name: Run unit tests for user-side functions
on:
workflow_call:
jobs:
unit_tests:
name: Unit
runs-on: ubuntu-latest
container: precice/precice:nightly
steps:
- uses: actions/checkout@v7
with:
path: micro-manager
- name: Install dependencies
run: |
apt-get -qq update
apt-get -qq install python3-dev python3-venv git pkg-config
- name: Load Cache OpenMPI 5
id: ompi-cache-load
uses: actions/cache/restore@v6
with:
path: ~/openmpi
key: openmpi-5.0.5-${{ runner.os }}-build
- name: Configure OpenMPI
run: |
if [ ! -d ~/openmpi ]; then
echo "::error::OpenMPI cache not found. The cache workflow may have failed."
exit 1
fi
cp -r ~/openmpi/* /usr/local/
ldconfig
which mpiexec
mpiexec --version
- name: Create a virtual environment and install Micro Manager in it
timeout-minutes: 6
working-directory: micro-manager
run: |
python3 -m venv .venv
. .venv/bin/activate
pip install .
- name: Run micro_manager unit test
working-directory: micro-manager
run: |
. .venv/bin/activate
pip uninstall -y pyprecice
cd tests/unit
python3 -m unittest test_micro_manager.py
- name: Run model adaptivity unit tests
working-directory: micro-manager
run: |
. .venv/bin/activate
cd tests/unit
python3 -m unittest test_model_adaptivity.py
- name: Install Micro Manager and run tasking unit test
working-directory: micro-manager
env:
OMPI_ALLOW_RUN_AS_ROOT: "1"
OMPI_ALLOW_RUN_AS_ROOT_CONFIRM: "1"
run: |
. .venv/bin/activate
cd tests/unit
python3 -m unittest test_tasking.py
- name: Install Micro Manager and run interpolation unit test
working-directory: micro-manager
run: |
. .venv/bin/activate
pip install .[sklearn]
pip uninstall -y pyprecice
cd tests/unit
python3 -m unittest test_interpolation.py
- name: Install Micro Manager and run micro simulation crash unit test
working-directory: micro-manager
run: |
. .venv/bin/activate
cd tests/unit
python3 -m unittest test_micro_simulation_crash_handling.py
- name: Install Micro Manager and run HDF5 read and write unit tests
working-directory: micro-manager/
run: |
. .venv/bin/activate
pip install .[snapshot]
pip uninstall -y pyprecice
cd tests/unit
python3 -m unittest test_hdf5_functionality.py
- name: Install Micro Manager and run snapshot_computation unit tests
working-directory: micro-manager
run: |
. .venv/bin/activate
cd tests/unit
python3 -m unittest test_snapshot_computation.py