File tree Expand file tree Collapse file tree 4 files changed +11
-9
lines changed Expand file tree Collapse file tree 4 files changed +11
-9
lines changed Original file line number Diff line number Diff line change @@ -96,6 +96,14 @@ function replace_version_pragmas
96
96
find . test -name ' *.sol' -type f -print0 | xargs -0 sed -i -E -e ' s/pragma solidity [^;]+;/pragma solidity >=0.0;/'
97
97
}
98
98
99
+ function neutralize_package_lock
100
+ {
101
+ # Remove lock files (if they exist) to prevent them from overriding our changes in package.json
102
+ printLog " Removing package lock files..."
103
+ rm --force --verbose yarn.lock
104
+ rm --force --verbose package-lock.json
105
+ }
106
+
99
107
function force_truffle_solc_modules
100
108
{
101
109
local soljson=" $1 "
Original file line number Diff line number Diff line change @@ -44,9 +44,7 @@ function ens_test
44
44
# Use latest Truffle. Older versions crash on the output from 0.8.0.
45
45
force_truffle_version ^5.1.55
46
46
47
- # Remove the lock file (if it exists) to prevent it from overriding our changes in package.json
48
- rm -f package-lock.json
49
-
47
+ neutralize_package_lock
50
48
replace_version_pragmas
51
49
force_truffle_solc_modules " $SOLJSON "
52
50
force_truffle_compiler_settings " $config_file " " ${DIR} /solc" " $min_optimizer_level "
Original file line number Diff line number Diff line change @@ -45,9 +45,7 @@ function gnosis_safe_test
45
45
sed -i ' s|github:gnosis/mock-contract#sol_0_5_0|github:solidity-external-tests/mock-contract#master_080|g' package.json
46
46
sed -i -E ' s|"@gnosis.pm/util-contracts": "[^"]+"|"@gnosis.pm/util-contracts": "github:solidity-external-tests/util-contracts#solc-7_080"|g' package.json
47
47
48
- # Remove the lock file (if it exists) to prevent it from overriding our changes in package.json
49
- rm -f package-lock.json
50
-
48
+ neutralize_package_lock
51
49
replace_version_pragmas
52
50
force_truffle_solc_modules " $SOLJSON "
53
51
force_truffle_compiler_settings " $config_file " " ${DIR} /solc" " $min_optimizer_level "
Original file line number Diff line number Diff line change @@ -43,9 +43,7 @@ function gnosis_safe_test
43
43
44
44
sed -i ' s|github:gnosis/mock-contract#sol_0_5_0|github:solidity-external-tests/mock-contract#master_080|g' package.json
45
45
46
- # Remove the lock file (if it exists) to prevent it from overriding our changes in package.json
47
- rm -f package-lock.json
48
-
46
+ neutralize_package_lock
49
47
replace_version_pragmas
50
48
force_truffle_solc_modules " $SOLJSON "
51
49
force_truffle_compiler_settings " $config_file " " ${DIR} /solc" " $min_optimizer_level "
You can’t perform that action at this time.
0 commit comments