pySim-prog_test: tolerate missing .data files

When the test detects a card, but does not find the .data faile for
it, then it fails. This can be a problem in case we want to intentionally
exclude a specific card model.

Related: OS#6532
Change-Id: Iba196ada0076385de7bffcb157a85fda0a6c1852
This commit is contained in:
Philipp Maier
2024-09-03 12:30:25 +02:00
parent 33256ddfed
commit 4d1f4fde4f

View File

@@ -134,6 +134,11 @@ function gen_ok_files {
continue
fi
echo "Card is of type: $CARD_NAME"
if ! [ -r "$CARD_NAME.data" ]; then
echo "Warning: no .data file for this card, skipping..."
continue
fi
gen_ok_file $I $CARD_NAME
done
}
@@ -163,6 +168,11 @@ function run_test {
ADM_HEX=""
ADM_OPT="-a"
if ! [ -r "$CARD_NAME.data" ]; then
echo "Warning: no .data file for this card, skipping..."
continue
fi
source "$CARD_NAME.data"
if [ -n "$ADM_HEX" ]; then
ADM_OPT="-A"