test: test dirs under _demo only has *.go files

This commit is contained in:
Li Jie
2024-11-26 11:52:56 +08:00
parent d879d0d924
commit 06cc43b11f

View File

@@ -1,13 +1,13 @@
#!/bin/bash
set -e
# llgo run subdirectories under _demo and _pydemo
# llgo run subdirectories under _demo and _pydemo that contain *.go files
total=0
failed=0
failed_cases=""
for d in ./_demo/* ./_pydemo/*; do
if [ -d "$d" ] && [ -n "$(ls "$d"/*.go 2>/dev/null)" ]; then
total=$((total+1))
if [ -d "$d" ]; then
echo "Testing $d"
if ! (cd "$d" && llgo run .); then
echo "FAIL"