Skip to content

Commit

Permalink
chore: replace md5 with sha in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
nmanoogian committed Feb 14, 2024
1 parent b2835e8 commit 27b85bd
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/e2e/install-sh-update-in-place.sh
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ afterAll() {
fi
}

md5hash() {
md5 -rq $1 || md5sum $1 | awk '{print $1}'
filehash() {
sha256sum "$1" | awk '{print $1}'
}

######################################################################
Expand Down Expand Up @@ -132,12 +132,12 @@ set +e
mkdir "$TEMP_INSTALL_DIR"
touch "$TEMP_INSTALL_DIR/doppler" && chmod +x "$TEMP_INSTALL_DIR/doppler"

empty_hash="$(md5hash "$TEMP_INSTALL_DIR/doppler")"
empty_hash="$(filehash "$TEMP_INSTALL_DIR/doppler")"
output="$("$DOPPLER_SCRIPTS_DIR/install.sh" --no-package-manager 2>&1)"
exit_code=$?
set -e

updated_hash="$(md5hash "$TEMP_INSTALL_DIR/doppler")"
updated_hash="$(filehash "$TEMP_INSTALL_DIR/doppler")"
installed_at="$(command -v doppler || true)"

actual_dir="$(dirname "$installed_at")"
Expand Down

0 comments on commit 27b85bd

Please sign in to comment.