Skip to content

Commit 21e29a3

Browse files
committed
fix(websocket): Use venv for running target tests
1 parent 9cec097 commit 21e29a3

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

.github/workflows/websocket__build-target-test.yml

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,14 +65,20 @@ jobs:
6565
with:
6666
name: websocket_bin_esp32_${{ matrix.idf_ver }}_${{ matrix.test.app }}
6767
path: ${{ env.TEST_DIR }}/ci/
68-
- name: Install Python packages
69-
env:
70-
PIP_EXTRA_INDEX_URL: "https://www.piwheels.org/simple"
71-
run: |
72-
pip install --only-binary cryptography --extra-index-url https://dl.espressif.com/pypi/ -r $GITHUB_WORKSPACE/ci/requirements.txt
7368
- name: Run Example Test on target
7469
working-directory: ${{ env.TEST_DIR }}
70+
env:
71+
PIP_EXTRA_INDEX_URL: "https://www.piwheels.org/simple"
7572
run: |
73+
sudo apt update
74+
sudo apt install -y software-properties-common
75+
sudo add-apt-repository ppa:deadsnakes/ppa
76+
sudo apt install -y python3.12 python3.12-venv python3.12-dev
77+
rm -rf .venv
78+
python3.12 -m venv .venv
79+
source .venv/bin/activate
80+
pip install --prefer-binary cryptography pytest-embedded pytest-embedded-serial-esp pytest-embedded-idf pytest-custom_exit_code esptool
81+
pip install --only-binary --extra-index-url https://dl.espressif.com/pypi/ -r $GITHUB_WORKSPACE/ci/requirements.txt
7682
unzip ci/artifacts.zip -d ci
7783
for dir in `ls -d ci/build_*`; do
7884
rm -rf build sdkconfig.defaults

0 commit comments

Comments
 (0)