Skip to content

Commit

Permalink
test: sequential unit tests 3.11, 3.12
Browse files Browse the repository at this point in the history
  • Loading branch information
maffettone committed May 10, 2024
1 parent 3597f00 commit d57edd9
Showing 1 changed file with 53 additions and 33 deletions.
86 changes: 53 additions & 33 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,7 @@ jobs:

runs-on: ubuntu-latest

strategy:
matrix:
python-version: ["3.11", "3.12"]

fail-fast: false
steps:

- uses: actions/checkout@v4

- name: Download and build bluesky-pods
Expand Down Expand Up @@ -59,33 +53,59 @@ jobs:
exit 1
fi
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
# - name: Set up Python ${{ matrix.python-version }}
# uses: actions/setup-python@v4
# with:
# python-version: ${{ matrix.python-version }}

- name: Install
shell: bash -l {0}
run: |
set -vxeuo pipefail
pip install --upgrade pip wheel
pip install .
pip install -r requirements-dev.txt
pip install -r requirements-agents.txt
mkdir -p /home/runner/.config/tiled/profiles
cp ./bluesky_adaptive/tests/podman/tiled_client_config.yml /home/runner/.config/tiled/profiles/tiled_client_config.yml
pip list
- name: Reload Permissions for QServer (Ensures plans are available)
shell: bash -l {0}
run: |
set -vxeuo pipefail
qserver environment open
qserver permissions reload
# - name: Install
# shell: bash -l {0}
# run: |
# set -vxeuo pipefail
# pip install --upgrade pip wheel
# pip install .
# pip install -r requirements-dev.txt
# pip install -r requirements-agents.txt
# mkdir -p /home/runner/.config/tiled/profiles
# cp ./bluesky_adaptive/tests/podman/tiled_client_config.yml /home/runner/.config/tiled/profiles/tiled_client_config.yml
# pip list

# - name: Reload Permissions for QServer (Ensures plans are available)
# shell: bash -l {0}
# run: |
# set -vxeuo pipefail
# qserver environment open
# qserver permissions reload

- name: Test with pytest
shell: bash -l {0}
- name: Setup and Test Python Versions
run: |
set -vxeuo pipefail
coverage run -m pytest -v
coverage report
for version in 3.11 3.12; do
echo "Setting up Python $version"
sudo apt-get install -y python$version python$version-venv
python$version -m venv venv
source venv/bin/activate
pip install --upgrade pip
pip install .
pip install -r requirements-dev.txt
pip install -r requirements-agents.txt
mkdir -p /home/runner/.config/tiled/profiles
cp ./bluesky_adaptive/tests/podman/tiled_client_config.yml /home/runner/.config/tiled/profiles/tiled_client_config.yml
pip list
qserver environment open
qserver permissions reload
echo "Running tests with Python $version"
coverage run -m pytest -v
coverage report
deactivate
rm -rf venv
done
# - name: Test with pytest
# shell: bash -l {0}
# run: |
# set -vxeuo pipefail
# coverage run -m pytest -v
# coverage report

0 comments on commit d57edd9

Please sign in to comment.