mirror of
https://github.com/vale981/ray
synced 2025-03-05 18:11:42 -05:00
[release][C++ API] support sanity check C++ (#18545)
This commit is contained in:
parent
bf1176311f
commit
beff857cc1
2 changed files with 19 additions and 3 deletions
|
@ -1,6 +1,6 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# This script automatically download ray and run the sanity check (sanity_check.py)
|
||||
# This script automatically download ray and run the sanity check (sanity_check.py and sanity_check_cpp.sh)
|
||||
# in various Python version. This script requires conda command to exist.
|
||||
|
||||
unset RAY_ADDRESS
|
||||
|
@ -44,9 +44,10 @@ do
|
|||
echo "========================================================="
|
||||
printf "\n\n\n"
|
||||
|
||||
pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple ray=="${RAY_VERSION}"
|
||||
pip install --index-url https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple ray=="${RAY_VERSION}" ray—cpp=="${RAY_VERSION}"
|
||||
|
||||
failed=false
|
||||
cpp_failed=false
|
||||
printf "\n\n\n"
|
||||
echo "========================================================="
|
||||
if python sanity_check.py; then
|
||||
|
@ -54,13 +55,21 @@ do
|
|||
else
|
||||
failed=true
|
||||
fi
|
||||
if sh sanity_check_cpp.sh; then
|
||||
echo "PYTHON ${PYTHON_VERSION} succeed sanity check C++."
|
||||
else
|
||||
cpp_failed=true
|
||||
fi
|
||||
echo "========================================================="
|
||||
printf "\n\n\n"
|
||||
|
||||
conda deactivate
|
||||
conda remove -y --name "${env_name}" --all
|
||||
if [ "$failed" = true ]; then
|
||||
echo "PYTHON ${PYTHON_VERSION} failed sanity check."
|
||||
exit 1
|
||||
fi
|
||||
if [ "$cpp_failed" = true ]; then
|
||||
echo "PYTHON ${PYTHON_VERSION} failed sanity check C++."
|
||||
exit 1
|
||||
fi
|
||||
done
|
||||
|
|
7
release/util/sanity_check_cpp.sh
Executable file
7
release/util/sanity_check_cpp.sh
Executable file
|
@ -0,0 +1,7 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
# This script generate a ray C++ template and run example
|
||||
set -e
|
||||
rm -rf ray-template && mkdir ray-template
|
||||
ray cpp --generate-bazel-project-template-to ray-template
|
||||
pushd ray-template && sh run.sh
|
Loading…
Add table
Reference in a new issue