trident: Update to match changes done to other external tests in the preset selection PR

This commit is contained in:
Kamil Śliwak 2022-01-10 21:28:32 +01:00
parent 4842774ab8
commit 823f0da3ee

View File

@ -58,9 +58,8 @@ function trident_test
legacy-optimize-evm+yul legacy-optimize-evm+yul
) )
local selected_optimizer_presets [[ $SELECTED_PRESETS != "" ]] || SELECTED_PRESETS=$(circleci_select_steps_multiarg "${settings_presets[@]}")
selected_optimizer_presets=$(circleci_select_steps_multiarg "${settings_presets[@]}") print_presets_or_exit "$SELECTED_PRESETS"
print_optimizer_presets_or_exit "$selected_optimizer_presets"
setup_solc "$DIR" "$BINARY_TYPE" "$BINARY_PATH" setup_solc "$DIR" "$BINARY_TYPE" "$BINARY_PATH"
download_project "$repo" "$ref_type" "$ref" "$DIR" download_project "$repo" "$ref_type" "$ref" "$DIR"
@ -71,7 +70,7 @@ function trident_test
neutralize_package_json_hooks neutralize_package_json_hooks
force_hardhat_compiler_binary "$config_file" "$BINARY_TYPE" "$BINARY_PATH" force_hardhat_compiler_binary "$config_file" "$BINARY_TYPE" "$BINARY_PATH"
force_hardhat_compiler_settings "$config_file" "$(first_word "$selected_optimizer_presets")" "$config_var" force_hardhat_compiler_settings "$config_file" "$(first_word "$SELECTED_PRESETS")" "$config_var"
yarn install yarn install
replace_version_pragmas replace_version_pragmas
@ -89,7 +88,7 @@ function trident_test
# version check. It's not used by tests so we can remove it. # version check. It's not used by tests so we can remove it.
rm -r node_modules/@sushiswap/core/ rm -r node_modules/@sushiswap/core/
for preset in $selected_optimizer_presets; do for preset in $SELECTED_PRESETS; do
hardhat_run_test "$config_file" "$preset" "${compile_only_presets[*]}" compile_fn test_fn "$config_var" hardhat_run_test "$config_file" "$preset" "${compile_only_presets[*]}" compile_fn test_fn "$config_var"
done done
} }