tcpreplay: add simple test.sh for all executables

Signed-off-by: Alexandru Ardelean <alex@shruggie.ro>
This commit is contained in:
Alexandru Ardelean
2024-07-17 14:58:16 +03:00
committed by Alexandru Ardelean
parent c986d6758f
commit f008af9060

15
net/tcpreplay/test.sh Normal file
View File

@@ -0,0 +1,15 @@
#!/bin/sh
[ "$1" = "tcpreplay-all" ] || exit 0
EXEC_LIST="tcpbridge tcpliveplay tcpreplay tcprewrite tcpcapinfo tcpprep tcpreplay-edit"
for executable in $EXEC_LIST ; do
$executable --version
$executable --version 2>&1 | grep "$2"
[ $? == 0 ] || {
echo "Problem or incorrect version for '$executable'"
exit 1
}
done