2012-02-09 23:18:17 +01:00
|
|
|
#!/bin/sh
|
|
|
|
|
#
|
2016-01-08 22:52:03 +01:00
|
|
|
# Run the Coverage test
|
|
|
|
|
#
|
2012-02-09 23:18:17 +01:00
|
|
|
|
2026-04-29 14:51:40 +02:00
|
|
|
# Ask root permissions at the start
|
|
|
|
|
sudo echo We are root
|
|
|
|
|
|
2012-02-09 23:18:17 +01:00
|
|
|
make distclean
|
|
|
|
|
|
2016-11-06 18:27:44 +01:00
|
|
|
if ! ./configure --enable-coverage --enable-sde; then
|
2012-02-09 23:18:17 +01:00
|
|
|
exit 1
|
|
|
|
|
fi
|
|
|
|
|
|
2026-02-28 10:08:09 +01:00
|
|
|
if ! make lcov_reset; then
|
2012-02-09 23:18:17 +01:00
|
|
|
exit 1
|
|
|
|
|
fi
|
|
|
|
|
|
2026-02-28 10:08:09 +01:00
|
|
|
if ! make check; then
|
|
|
|
|
exit 1
|
|
|
|
|
fi
|
|
|
|
|
|
2026-04-29 14:51:40 +02:00
|
|
|
# Root test for Btrfs
|
2026-08-12 00:23:54 +02:00
|
|
|
sudo make snapcheck
|
2026-04-29 14:51:40 +02:00
|
|
|
|
2026-02-28 10:08:09 +01:00
|
|
|
# Run commands on a real array to test smartctl
|
|
|
|
|
sudo ./snapraid probe
|
|
|
|
|
sudo ./snapraid up
|
|
|
|
|
sudo ./snapraid smart
|
|
|
|
|
sudo ./snapraid probe
|
|
|
|
|
sudo ./snapraid devices
|
|
|
|
|
sudo ./snapraid down
|
2026-04-29 14:51:40 +02:00
|
|
|
sudo ./snapraid test-downifup
|
2012-02-09 23:18:17 +01:00
|
|
|
|
2026-02-28 10:08:09 +01:00
|
|
|
if ! make lcov_capture lcov_html; then
|
|
|
|
|
exit 1
|
|
|
|
|
fi
|
2026-04-29 14:51:40 +02:00
|
|
|
|
|
|
|
|
# Remove root generated files
|
|
|
|
|
sudo make clean
|