2015-04-17 02:36:46 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
set -eux
|
|
|
|
set -o pipefail
|
|
|
|
|
|
|
|
basedir=$(dirname $0)
|
|
|
|
source $basedir/test_functions.bash
|
|
|
|
|
|
|
|
for test_element in $basedir/../elements/*/test-elements/*; do
|
|
|
|
if [ -d "$test_element" ]; then
|
|
|
|
# our element name is two dirs up
|
|
|
|
element_name=$(basename $(dirname $(dirname $test_element)))
|
2015-09-22 12:22:27 +00:00
|
|
|
element_type=disk
|
|
|
|
if [ -f "$test_element/element-type" ]; then
|
|
|
|
element_type=$(cat "$test_element/element-type")
|
|
|
|
fi
|
|
|
|
run_${element_type}_element_test "$(basename $test_element)" "$element_name"
|
2015-04-17 02:36:46 +00:00
|
|
|
fi
|
|
|
|
done
|