Added various contracts for testing.

This commit is contained in:
chriseth
2017-07-05 12:39:55 +02:00
parent 05a26fc98c
commit ac84b36144
71 changed files with 10063 additions and 3 deletions
+20 -3
View File
@@ -30,13 +30,30 @@ set -e
REPO_ROOT="$(dirname "$0")"/..
echo "Running commandline tests..."
"$REPO_ROOT/test/cmdlineTests.sh"
echo "Checking that StandardToken.sol, owned.sol and mortal.sol produce bytecode..."
output=$("$REPO_ROOT"/build/solc/solc --bin "$REPO_ROOT"/std/*.sol 2>/dev/null | grep "ffff" | wc -l)
test "${output//[[:blank:]]/}" = "3"
echo "Compiling various other contracts and libraries..."
(
cd "$REPO_ROOT"/test/compilationTests/
for dir in *
do
if [ "$dir" != "README.md" ]
then
echo " - $dir"
cd "$dir"
../../../build/solc/solc --optimize \
--combined-json abi,asm,ast,bin,bin-runtime,clone-bin,compact-format,devdoc,hashes,interface,metadata,opcodes,srcmap,srcmap-runtime,userdoc \
*.sol */*.sol > /dev/null 2>&1
cd ..
fi
done
)
echo "Running commandline tests..."
"$REPO_ROOT/test/cmdlineTests.sh"
# This conditional is only needed because we don't have a working Homebrew
# install for `eth` at the time of writing, so we unzip the ZIP file locally
# instead. This will go away soon.