Commit 056cb982 authored by Mark Tyneway's avatar Mark Tyneway

contracts-bedrock: fix slither

`slither` crashes on new solidity features, one is used
in the forge tests. Not exactly sure what it is, but
this will prevent that problem by moving the tests
to a temp dir when running slither and then moving them
back.
parent 70bf922a
---
'@eth-optimism/contracts-bedrock': patch
---
Fix slither script
......@@ -16,6 +16,7 @@ remappings = [
extra_output = ['devdoc', 'userdoc', 'metadata', 'storageLayout']
bytecode_hash = 'none'
build_info = true
build_info_path = 'artifacts/build-info'
ffi = true
fuzz_runs = 16
......
#!/bin/bash
if [ ! -d forge-artifacts/build-info ]; then
npx hardhat compile
fi
# Handle slither bug unable to work with the foundry tests
TEMP=$(mktemp -d)
mv contracts/test $TEMP/test
cp -rf forge-artifacts/build-info artifacts/build-info
slither .
mv $TEMP/test contracts/test
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment