Skip to content

Commit a951ae7

Browse files
committed
modify
1 parent 265687a commit a951ae7

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

.github/workflows/action_auto_utest.yml

+10-10
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ jobs:
5959
TEST_BSP_ROOT: ${{ matrix.platform.RTT_BSP }}
6060
TEST_CONFIG_FILE: ${{ matrix.config_file }}
6161
TEST_SD_FILE: ${{ matrix.platform.SD_FILE }}
62-
RUN_FLAG: ${{ matrix.platform.RUN }}
62+
RUN_FLAG: ${{ RUN_FLAG }}
6363
KERNEL_FLAG: ${{ matrix.platform.KERNEL }}
6464
steps:
6565
- uses: actions/checkout@v4
@@ -77,7 +77,7 @@ jobs:
7777
TOOLCHAIN_INSTALLED=""
7878
7979
# Install Arm ToolChains
80-
if [[ "${{ matrix.platform.QEMU_ARCH }}" == "arm" && "${{ matrix.platform.KERNEL }}" == "standard" && "${{ matrix.config_file }}" != "rtsmart/rtsmart.cfg" ]]; then
80+
if [ TEST_QEMU_ARCH == "arm" && KERNEL_FLAG == "standard" && TEST_CONFIG_FILE != "rtsmart/rtsmart.cfg" ]; then
8181
wget -q https://github.com/RT-Thread/toolchains-ci/releases/download/v1.3/gcc-arm-none-eabi-10-2020-q4-major-x86_64-linux.tar.bz2
8282
sudo tar xjf gcc-arm-none-eabi-10-2020-q4-major-x86_64-linux.tar.bz2 -C /opt
8383
/opt/gcc-arm-none-eabi-10-2020-q4-major/bin/arm-none-eabi-gcc --version
@@ -87,7 +87,7 @@ jobs:
8787
fi
8888
8989
# Install Arm Musl ToolChains
90-
if [[ "${{ matrix.platform.QEMU_ARCH }}" == "arm" && "${{ matrix.platform.KERNEL }}" == "rtsmart" && "${{ matrix.config_file }}" == "rtsmart/rtsmart.cfg" ]]; then
90+
if [ TEST_QEMU_ARCH == "arm" && KERNEL_FLAG == "rtsmart" && TEST_CONFIG_FILE == "rtsmart/rtsmart.cfg" ]; then
9191
wget -q https://github.com/RT-Thread/toolchains-ci/releases/download/v1.7/arm-linux-musleabi_for_x86_64-pc-linux-gnu_stable.tar.bz2
9292
sudo tar xjf arm-linux-musleabi_for_x86_64-pc-linux-gnu_stable.tar.bz2 -C /opt
9393
/opt/arm-linux-musleabi_for_x86_64-pc-linux-gnu/bin/arm-linux-musleabi-gcc --version
@@ -97,7 +97,7 @@ jobs:
9797
fi
9898
9999
# Install RISC-V ToolChains
100-
if [[ "${{ matrix.platform.QEMU_ARCH }}" == "riscv64" && "${{ matrix.platform.KERNEL }}" == "standard" && "${{ matrix.config_file }}" != "rtsmart/rtsmart.cfg" ]]; then
100+
if [ "TEST_QEMU_ARCH == "riscv64" && KERNEL_FLAG == "standard" && TEST_CONFIG_FILE != "rtsmart/rtsmart.cfg" ]; then
101101
wget -q https://github.com/RT-Thread/toolchains-ci/releases/download/v1.4/riscv64-unknown-elf-toolchain-10.2.0-2020.12.8-x86_64-linux-ubuntu14.tar.gz
102102
sudo tar zxvf riscv64-unknown-elf-toolchain-10.2.0-2020.12.8-x86_64-linux-ubuntu14.tar.gz -C /opt
103103
/opt/riscv64-unknown-elf-toolchain-10.2.0-2020.12.8-x86_64-linux-ubuntu14/bin/riscv64-unknown-elf-gcc --version
@@ -106,7 +106,7 @@ jobs:
106106
fi
107107
108108
# Install RISC-V Musl ToolChains
109-
if [[ "${{ matrix.platform.QEMU_ARCH }}" == "riscv64" && "${{ matrix.platform.KERNEL }}" == "rtsmart" && "${{ matrix.config_file }}" == "rtsmart/rtsmart.cfg" ]]; then
109+
if [ TEST_QEMU_ARCH == "riscv64" && KERNEL_FLAG == "rtsmart" && TEST_CONFIG_FILE == "rtsmart/rtsmart.cfg" ]; then
110110
wget -q https://github.com/RT-Thread/toolchains-ci/releases/download/v1.7/riscv64-linux-musleabi_for_x86_64-pc-linux-gnu_latest.tar.bz2
111111
sudo tar xjf riscv64-linux-musleabi_for_x86_64-pc-linux-gnu_latest.tar.bz2 -C /opt
112112
/opt/riscv64-linux-musleabi_for_x86_64-pc-linux-gnu/bin/riscv64-unknown-linux-musl-gcc --version
@@ -116,7 +116,7 @@ jobs:
116116
fi
117117
118118
# Install AARCH64 Musl ToolChains
119-
if [[ "${{ matrix.platform.QEMU_ARCH }}" == "aarch64" && "${{ matrix.platform.KERNEL }}" == "rtsmart" && "${{ matrix.config_file }}" == "rtsmart/rtsmart.cfg" ]]; then
119+
if [ TEST_QEMU_ARCH == "aarch64" && KERNEL_FLAG == "rtsmart" && TEST_CONFIG_FILE == "rtsmart/rtsmart.cfg" ]; then
120120
wget -q https://github.com/RT-Thread/toolchains-ci/releases/download/v1.7/aarch64-linux-musleabi_for_x86_64-pc-linux-gnu_stable.tar.bz2
121121
sudo tar xjf aarch64-linux-musleabi_for_x86_64-pc-linux-gnu_stable.tar.bz2 -C /opt
122122
/opt/aarch64-linux-musleabi_for_x86_64-pc-linux-gnu/bin/aarch64-linux-musleabi-gcc --version
@@ -126,7 +126,7 @@ jobs:
126126
fi
127127
128128
# Install CPP11 Preprocessing Toolchain
129-
if [[ "${{ matrix.platform.QEMU_ARCH }}" == "arm" && "${{ matrix.config_file }}" == "cpp11/cpp11.cfg" ]]; then
129+
if [ TEST_QEMU_ARCH == "arm" && TEST_CONFIG_FILE == "cpp11/cpp11.cfg" ]; then
130130
sudo rm -f /opt/gcc-arm-none-eabi-10-2020-q4-major/arm-none-eabi/include/c++/10.2.1/thread
131131
sudo rm -f /opt/gcc-arm-none-eabi-10-2020-q4-major/arm-none-eabi/include/c++/10.2.1/mutex
132132
sudo rm -f /opt/gcc-arm-none-eabi-10-2020-q4-major/arm-none-eabi/include/c++/10.2.1/condition_variable
@@ -138,18 +138,18 @@ jobs:
138138
139139
if [[ -z "$TOOLCHAIN_INSTALLED" ]]; then
140140
echo "No valid toolchain installed, stopping the workflow."
141-
exit 1
142141
fi
143142
144143
- name: Build BSP
144+
if: ${{ RUN_FLAG == 'yes' && env.TOOLCHAIN_INSTALLED != '' && success() }}
145145
run: |
146146
echo CONFIG_RT_USING_UTESTCASES=y >> $TEST_BSP_ROOT/.config
147147
cat .github/utest/$TEST_CONFIG_FILE >> $TEST_BSP_ROOT/.config
148148
scons --pyconfig-silent -C $TEST_BSP_ROOT
149149
scons -j$(nproc) --strict -C $TEST_BSP_ROOT
150150
151151
- name: QEMU Run Test
152-
if: ${{ matrix.platform.RUN == 'yes' && env.TOOLCHAIN_INSTALLED != '' && success() }}
152+
if: ${{ RUN_FLAG == 'yes' && env.TOOLCHAIN_INSTALLED != '' && success() }}
153153
run: |
154154
if [ "$TEST_SD_FILE" != "None" ]; then
155155
dd if=/dev/zero of=$TEST_BSP_ROOT/sd.bin bs=1024 count=65536
@@ -162,7 +162,7 @@ jobs:
162162
disown $QEMU_PID
163163
164164
- name: Monitor qemu log
165-
if: ${{ matrix.platform.RUN == 'yes' && env.TOOLCHAIN_INSTALLED != '' && success() }}
165+
if: ${{ RUN_FLAG == 'yes' && env.TOOLCHAIN_INSTALLED != '' && success() }}
166166
run: |
167167
FAILURE_DETECTED=false
168168
ERROR_LOGS=""

0 commit comments

Comments
 (0)