mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-21 05:43:48 -07:00
pm3test: remove spurious spaces
This commit is contained in:
parent
c832ae1f15
commit
2a91310bf5
1 changed files with 12 additions and 12 deletions
24
pm3test.sh
24
pm3test.sh
|
@ -11,17 +11,17 @@ C_NC='\033[0m' # No Color
|
||||||
|
|
||||||
# title, file name or file wildcard to check
|
# title, file name or file wildcard to check
|
||||||
function CheckFileExist() {
|
function CheckFileExist() {
|
||||||
|
|
||||||
if [ -f "$2" ]; then
|
if [ -f "$2" ]; then
|
||||||
echo -e "$1 ${C_GREEN}[OK]${C_NC}"
|
echo -e "$1 ${C_GREEN}[OK]${C_NC}"
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ls $2 1> /dev/null 2>&1; then
|
if ls $2 1> /dev/null 2>&1; then
|
||||||
echo -e "$1 ${C_GREEN}[OK]${C_NC}"
|
echo -e "$1 ${C_GREEN}[OK]${C_NC}"
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo -e "$1 ${C_RED}[Fail]${C_NC}"
|
echo -e "$1 ${C_RED}[Fail]${C_NC}"
|
||||||
return 1
|
return 1
|
||||||
}
|
}
|
||||||
|
@ -34,8 +34,8 @@ function CheckExecute() {
|
||||||
else
|
else
|
||||||
local RETRY="e"
|
local RETRY="e"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
for I in $RETRY
|
for I in $RETRY
|
||||||
do
|
do
|
||||||
if eval "$2 | grep -q '$3'"; then
|
if eval "$2 | grep -q '$3'"; then
|
||||||
echo -e "$1 ${C_GREEN}[OK]${C_NC}"
|
echo -e "$1 ${C_GREEN}[OK]${C_NC}"
|
||||||
|
@ -43,13 +43,13 @@ function CheckExecute() {
|
||||||
fi
|
fi
|
||||||
if [ ! $I == "e" ]; then echo "retry $I"; fi
|
if [ ! $I == "e" ]; then echo "retry $I"; fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|
||||||
if [ $5 ]; then
|
if [ $5 ]; then
|
||||||
echo -e "$1 ${C_YELLOW}[Ignored]${C_NC}"
|
echo -e "$1 ${C_YELLOW}[Ignored]${C_NC}"
|
||||||
return 0
|
return 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
echo -e "$1 ${C_RED}[Fail]${C_NC}"
|
echo -e "$1 ${C_RED}[Fail]${C_NC}"
|
||||||
return 1
|
return 1
|
||||||
}
|
}
|
||||||
|
@ -67,9 +67,9 @@ if [ "$TRAVIS_COMMIT" ]; then
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
printf "git branch: "
|
printf "git branch: "
|
||||||
git describe --all
|
git describe --all
|
||||||
printf "git sha: "
|
printf "git sha: "
|
||||||
git rev-parse HEAD
|
git rev-parse HEAD
|
||||||
echo ""
|
echo ""
|
||||||
|
|
||||||
|
@ -88,7 +88,7 @@ while true; do
|
||||||
if ! CheckExecute "hf mf hardnested test" "./client/proxmark3 -c 'hf mf hardnested t 1 000000000000'" "found:" "repeat" "ignore"; then break; fi
|
if ! CheckExecute "hf mf hardnested test" "./client/proxmark3 -c 'hf mf hardnested t 1 000000000000'" "found:" "repeat" "ignore"; then break; fi
|
||||||
if ! CheckExecute "hf mf iclass test" "./client/proxmark3 -c 'hf iclass loclass t'" "verified ok"; then break; fi
|
if ! CheckExecute "hf mf iclass test" "./client/proxmark3 -c 'hf iclass loclass t'" "verified ok"; then break; fi
|
||||||
if ! CheckExecute "emv test" "./client/proxmark3 -c 'emv test'" "Test(s) \[ OK"; then break; fi
|
if ! CheckExecute "emv test" "./client/proxmark3 -c 'emv test'" "Test(s) \[ OK"; then break; fi
|
||||||
|
|
||||||
printf "\n${C_GREEN}Tests [OK]${C_NC}\n\n"
|
printf "\n${C_GREEN}Tests [OK]${C_NC}\n\n"
|
||||||
exit 0
|
exit 0
|
||||||
done
|
done
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue