mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-08-03 17:29:01 +00:00
Modify test call for test_model_registration.py within workflow
This commit is contained in:
parent
fa99fbfb39
commit
e5da50fcc3
1 changed files with 11 additions and 1 deletions
|
@ -258,7 +258,17 @@ jobs:
|
|||
for file in "$dir"/test_*.py; do
|
||||
test_name=$(basename "$file")
|
||||
new_file="result-${dir_name}-${test_name}.xml"
|
||||
if torchrun $(which pytest) -s -v ${TESTS_PATH}/${dir_name}/${test_name} -m "${PROVIDER_ID} and ${MODEL_ID}" \
|
||||
#TODO
|
||||
# Add if test_name = test_model_registration.py then echo "hello"
|
||||
if [ "$test_name" = "test_model_registration.py" ]; then
|
||||
echo "Found test_model_registration.py"
|
||||
if torchrun $(which pytest) -v -s -k "${PROVIDER_ID}" --inference-model="${MODEL_ID}" \
|
||||
--junitxml="${{ github.workspace }}/${new_file}"; then
|
||||
echo "Ran the test_model_registration.py"
|
||||
else
|
||||
echo "Did NOT run the test_model_registration.py"
|
||||
fi
|
||||
elif torchrun $(which pytest) -s -v ${TESTS_PATH}/${dir_name}/${test_name} -m "${PROVIDER_ID} and ${MODEL_ID}" \
|
||||
--junitxml="${{ github.workspace }}/${new_file}"; then
|
||||
echo "Ran test: ${test_name}"
|
||||
else
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue