Skip to content

Commit e174565

Browse files
committed
use only folders for tests
Signed-off-by: Ben <[email protected]>
1 parent 7ad0d7f commit e174565

File tree

1 file changed

+17
-15
lines changed

1 file changed

+17
-15
lines changed

scripts/run-all-control-tests.sh

+17-15
Original file line numberDiff line numberDiff line change
@@ -29,22 +29,24 @@ fi
2929
result=0
3030
# Run all control tests
3131
for control in $(ls controls); do
32-
echo "=================================================="
33-
echo "Running test $control"
34-
echo "--------------------------------------------------"
35-
pushd controls/$control
36-
$PYTHON_EXECUTABLE ../../scripts/run-control-tests.py
37-
TEST_RESULT=$?
38-
# Check if test failed
39-
echo "--------------------------------------------------"
40-
if [ $TEST_RESULT -ne 0 ]; then
41-
echo "Test $control failed"
42-
result=1
43-
else
44-
echo "Test $control passed"
32+
if [[ -d $control ]]; then
33+
echo "=================================================="
34+
echo "Running test $control"
35+
echo "--------------------------------------------------"
36+
pushd controls/$control
37+
$PYTHON_EXECUTABLE ../../scripts/run-control-tests.py
38+
TEST_RESULT=$?
39+
# Check if test failed
40+
echo "--------------------------------------------------"
41+
if [ $TEST_RESULT -ne 0 ]; then
42+
echo "Test $control failed"
43+
result=1
44+
else
45+
echo "Test $control passed"
46+
fi
47+
popd
48+
echo "=================================================="
4549
fi
46-
popd
47-
echo "=================================================="
4850
done
4951

5052
exit $result

0 commit comments

Comments
 (0)