aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorchriseth <chris@ethereum.org>2017-07-12 21:03:29 +0800
committerGitHub <noreply@github.com>2017-07-12 21:03:29 +0800
commit106acd9cbb827a39cd9bfd67866dafe0eeeb31de (patch)
treed51cec3ba7cad7ccad440312ae2e19a7a62d2509 /scripts
parentfca8d781b4490026dce657fd344a1fe36c9179f2 (diff)
parentac84b36144f746662e5ddb984d283e053c7d06ba (diff)
downloaddexon-solidity-106acd9cbb827a39cd9bfd67866dafe0eeeb31de.tar.gz
dexon-solidity-106acd9cbb827a39cd9bfd67866dafe0eeeb31de.tar.zst
dexon-solidity-106acd9cbb827a39cd9bfd67866dafe0eeeb31de.zip
Merge pull request #2522 from ethereum/testCode
Added various contracts for testing.
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/tests.sh23
1 files changed, 20 insertions, 3 deletions
diff --git a/scripts/tests.sh b/scripts/tests.sh
index 6b76c154..64b4121f 100755
--- a/scripts/tests.sh
+++ b/scripts/tests.sh
@@ -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.