Skip to content

Commit

Permalink
Fix defects raised by ShellCheck
Browse files Browse the repository at this point in the history
Signed-off-by: Anderson Toshiyuki Sasaki <[email protected]>
  • Loading branch information
ansasaki authored and kkaarreell committed Aug 4, 2023
1 parent 89255c5 commit b63aa68
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions Library/test-helpers/lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1222,7 +1222,7 @@ limeWaitForAgentRegistration() {
for I in `seq $TIMEOUT`; do
timeout $TIMEOUT keylime_tenant -c regstatus -u $UUID &> $OUTPUT
REGSTATE=$(cat $OUTPUT | grep "^{" | jq -r ".[].operational_state")
if [ "$REGSTATE" == "Registered" ]; then
if [ "$REGSTATE" == "Registered" ]; then
cat $OUTPUT
rm $OUTPUT
return 0
Expand Down Expand Up @@ -2538,7 +2538,7 @@ if ! id ${limeTestUser}; then
fi

# delete previously existing TPM data
rm -f ${__INTERNAL_limeTPMDetails}
rm -f "${__INTERNAL_limeTPMDetails}"

# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Verification
Expand All @@ -2552,10 +2552,10 @@ rm -f ${__INTERNAL_limeTPMDetails}

limeLibraryLoaded() {

local PACKAGES="tpm2-tools openssl beakerlib podman nmap jq"
local PACKAGES=(tpm2-tools openssl beakerlib podman nmap jq)

echo -e "\nInstall packages required by the library when missing."
rpm -q $PACKAGES || yum -y install $PACKAGES
rpm -q "${PACKAGES[@]}" || yum -y install "${PACKAGES[@]}"

if [ -n "$__INTERNAL_limeTmpDir" ]; then
rlLogDebug "Library keylime/test-helpers loaded."
Expand Down

0 comments on commit b63aa68

Please sign in to comment.