btrfs-progs/tests/check-setup.sh
Yaroslav Halchenko 16a7cbca91 btrfs-progs: run codespell throughout fixing typos automagically
Spell checking can now run in automated mode.

=== Do not change lines below ===
{
 "chain": [],
 "cmd": "codespell -w",
 "exit": 0,
 "extra_inputs": [],
 "inputs": [],
 "outputs": [],
 "pwd": "."
}
^^^ Do not change lines above ^^^

Author: Yaroslav Halchenko <debian@onerussian.com>
Signed-off-by: David Sterba <dsterba@suse.com>
2024-07-30 19:56:08 +02:00

24 lines
535 B
Bash
Executable File

#!/bin/bash
#
# Check that the system setup and configuration are sufficient for all tests to run
for dir in *-tests; do
missing=
echo "Checking prerequisites for: $dir"
for prog in $(find "$dir" -name 'test.sh' -exec grep check_global_prereq '{}' \; | sort -u); do
if [ "$prog" = check_global_prereq ]; then
continue
fi
if type -p "$prog" &> /dev/null; then
echo "Check $prog: OK"
else
echo "Check $prog: MISSING"
missing+=" $prog"
fi
done
if ! [ -z "$missing" ]; then
echo "MISSING: $missing"
fi
done