Skip to content

Commit 1612836

Browse files
tehampsonpull[bot]
authored andcommitted
Remove include_yamltests arg, and always install the whl for python tests (#29456)
* Remove include_yamltests arg, and install always for python tests * CI fixes * CI fixes
1 parent c8498d3 commit 1612836

File tree

2 files changed

+8
-14
lines changed

2 files changed

+8
-14
lines changed

.github/workflows/tests.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ jobs:
184184
"
185185
- name: Build Apps
186186
run: |
187-
scripts/run_in_build_env.sh './scripts/build_python.sh --install_virtual_env out/venv --include_yamltests'
187+
scripts/run_in_build_env.sh './scripts/build_python.sh --install_virtual_env out/venv'
188188
./scripts/run_in_build_env.sh \
189189
"./scripts/build/build_examples.py \
190190
--target linux-x64-chip-tool${CHIP_TOOL_VARIANT}-${BUILD_VARIANT} \

scripts/build_python.sh

+7-13
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ Input Options:
6868
src/python_testing scripts.
6969
Defaults to yes.
7070
--extra_packages PACKAGES Install extra Python packages from PyPI
71-
--include_yamltests Whether to install the matter_yamltests wheel.
7271
-z --pregen_dir DIRECTORY Directory where generated zap files have been pre-generated.
7372
"
7473
}
@@ -129,9 +128,6 @@ while (($#)); do
129128
extra_packages=$2
130129
shift
131130
;;
132-
--include_yamltests)
133-
include_yamltests="yes"
134-
;;
135131
--pregen_dir | -z)
136132
pregen_dir=$2
137133
shift
@@ -187,15 +183,6 @@ else
187183
WHEEL=("$OUTPUT_ROOT"/controller/python/chip*.whl)
188184
fi
189185

190-
if [ -n "$include_yamltests" ]; then
191-
YAMLTESTS_GN_LABEL="//scripts:matter_yamltests_distribution._build_wheel"
192-
193-
# Add wheels from pw_python_package or pw_python_distribution templates.
194-
WHEEL+=(
195-
"$(ls -tr "$(wheel_output_dir "$YAMLTESTS_GN_LABEL")"/*.whl | head -n 1)"
196-
)
197-
fi
198-
199186
if [ -n "$extra_packages" ]; then
200187
WHEEL+=("$extra_packages")
201188
fi
@@ -217,7 +204,14 @@ if [ -n "$install_virtual_env" ]; then
217204
"$ENVIRONMENT_ROOT"/bin/pip install --upgrade "${WHEEL[@]}"
218205

219206
if [ "$install_pytest_requirements" = "yes" ]; then
207+
YAMLTESTS_GN_LABEL="//scripts:matter_yamltests_distribution._build_wheel"
208+
# Add wheels from pw_python_package or pw_python_distribution templates.
209+
YAMLTEST_WHEEL=(
210+
"$(ls -tr "$(wheel_output_dir "$YAMLTESTS_GN_LABEL")"/*.whl | head -n 1)"
211+
)
212+
220213
echo_blue "Installing python test dependencies ..."
214+
"$ENVIRONMENT_ROOT"/bin/pip install --upgrade "${YAMLTEST_WHEEL[@]}"
221215
"$ENVIRONMENT_ROOT"/bin/pip install -r "$CHIP_ROOT/scripts/tests/requirements.txt"
222216
"$ENVIRONMENT_ROOT"/bin/pip install -r "$CHIP_ROOT/src/python_testing/requirements.txt"
223217
fi

0 commit comments

Comments
 (0)