From bbf2471f64271d223a526f3c77c2457d6e7aa2a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kamil=20=C5=9Aliwak?= Date: Wed, 2 Dec 2020 00:55:12 +0100 Subject: [PATCH] External tests: Replace hard-coded version in force_truffle_version() with a parameter --- test/externalTests/common.sh | 4 ++-- test/externalTests/gnosis.sh | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/test/externalTests/common.sh b/test/externalTests/common.sh index 5a9f42ba2..d56912a85 100644 --- a/test/externalTests/common.sh +++ b/test/externalTests/common.sh @@ -85,9 +85,9 @@ function download_project function force_truffle_version { - local repo="$1" + local version="$1" - sed -i 's/"truffle":\s*".*"/"truffle": "^5.0.42"/g' package.json + sed -i 's/"truffle":\s*".*"/"truffle": "'"$version"'"/g' package.json } function truffle_setup diff --git a/test/externalTests/gnosis.sh b/test/externalTests/gnosis.sh index 07c34ca46..8a5ccd0c7 100755 --- a/test/externalTests/gnosis.sh +++ b/test/externalTests/gnosis.sh @@ -35,7 +35,7 @@ function gnosis_safe_test truffle_setup https://github.com/solidity-external-tests/safe-contracts.git development_070 - force_truffle_version + force_truffle_version ^5.0.42 sed -i 's|github:gnosis/mock-contract#sol_0_5_0|github:solidity-external-tests/mock-contract#master_070|g' package.json rm -f package-lock.json rm -rf node_modules/