[fuzzing] Only use docker image on x86_64 machines
The echidna docker image does not support ARM Macs, for example.
This commit is contained in:
parent
b396f13359
commit
f530bc5081
|
@ -2,6 +2,7 @@
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
root=$(cd $(dirname "$0")/.. && pwd)
|
root=$(cd $(dirname "$0")/.. && pwd)
|
||||||
|
arch=$(arch)
|
||||||
|
|
||||||
if command -v echidna; then
|
if command -v echidna; then
|
||||||
fuzz () {
|
fuzz () {
|
||||||
|
@ -11,7 +12,7 @@ if command -v echidna; then
|
||||||
--crytic-args --ignore-compile \
|
--crytic-args --ignore-compile \
|
||||||
--contract $1
|
--contract $1
|
||||||
}
|
}
|
||||||
else
|
elif [ "${arch}" = "x86_64" ]; then
|
||||||
fuzz () {
|
fuzz () {
|
||||||
docker run \
|
docker run \
|
||||||
--rm \
|
--rm \
|
||||||
|
@ -23,6 +24,10 @@ else
|
||||||
--crytic-args --ignore-compile \
|
--crytic-args --ignore-compile \
|
||||||
--contract $1"
|
--contract $1"
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
echo "Error: echidna not found, and the docker image does not support ${arch}"
|
||||||
|
echo "Please install echidna: https://github.com/crytic/echidna#installation"
|
||||||
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
fuzz FuzzMarketplace
|
fuzz FuzzMarketplace
|
||||||
|
|
Loading…
Reference in New Issue