diff options
author | chriseth <chris@ethereum.org> | 2018-02-22 22:06:14 +0800 |
---|---|---|
committer | chriseth <chris@ethereum.org> | 2018-02-22 22:17:43 +0800 |
commit | b5a3b6a4293537c843e8387ffd0b03253160dc0a (patch) | |
tree | da9c796dc3676a92a8e8ff14c34068fb690e5699 /test/libsolidity | |
parent | ad010f557bc4af683688aef423e7ae68d0fd4d08 (diff) | |
download | dexon-solidity-b5a3b6a4293537c843e8387ffd0b03253160dc0a.tar.gz dexon-solidity-b5a3b6a4293537c843e8387ffd0b03253160dc0a.tar.zst dexon-solidity-b5a3b6a4293537c843e8387ffd0b03253160dc0a.zip |
Parser test.
Diffstat (limited to 'test/libsolidity')
-rw-r--r-- | test/libsolidity/SolidityParser.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/libsolidity/SolidityParser.cpp b/test/libsolidity/SolidityParser.cpp index 861e6408..b7097d0f 100644 --- a/test/libsolidity/SolidityParser.cpp +++ b/test/libsolidity/SolidityParser.cpp @@ -1708,6 +1708,19 @@ BOOST_AUTO_TEST_CASE(newInvalidTypeName) CHECK_PARSE_ERROR(text, "Expected explicit type name"); } +BOOST_AUTO_TEST_CASE(emitWithoutEvent) +{ + char const* text = R"( + contract C { + event A(); + function f() { + emit A; + } + } + )"; + CHECK_PARSE_ERROR(text, "Expected token LParen got 'Semicolon'"); +} + BOOST_AUTO_TEST_SUITE_END() } |