Skip to content

Commit acaa777

Browse files
authored
Merge pull request #280 from labthings/test-against-ofm
Add a CI job to test against the OFM test suite
2 parents 517dc8e + 2a10623 commit acaa777

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

.github/workflows/test.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -152,3 +152,48 @@ jobs:
152152
minimum-ratio: 0
153153
send-summary-comment: true
154154
show-annotations: "warning"
155+
156+
test-against-ofm:
157+
runs-on: ubuntu-latest
158+
continue-on-error: true
159+
defaults:
160+
run:
161+
working-directory: /home/runner/work/openflexure-microscope-server/
162+
steps:
163+
- uses: actions/checkout@v3
164+
165+
- name: Set up Python
166+
uses: actions/setup-python@v4
167+
with:
168+
python-version: 3.11
169+
170+
- name: Install OpenFlexure Microscope Server
171+
working-directory: /home/runner/work/
172+
run: |
173+
git clone https://gitlab.com/openflexure/openflexure-microscope-server.git
174+
cd openflexure-microscope-server
175+
git checkout v3
176+
pip install -e .[dev]
177+
178+
- name: Install LabThings-FastAPI
179+
run: pip install -e ../labthings-fastapi/labthings-fastapi/
180+
181+
- name: Configure Git identity
182+
run: |
183+
git config --global user.name "Sir Unit of Test"
184+
git config --global user.email "bogus@email.com"
185+
186+
- name: Pull OFM web app
187+
run: python ./pull_webapp.py
188+
189+
- name: Run OFM unit tests
190+
run: pytest
191+
192+
- name: Run OFM integration tests
193+
run: pytest tests/integration_tests
194+
195+
- name: Run OFM lifecycle test
196+
run: tests/lifecycle_test/testfile.py
197+
198+
- name: Type check with `mypy`
199+
run: mypy src

0 commit comments

Comments
 (0)