Index: tools/gn/parser_unittest.cc |
diff --git a/tools/gn/parser_unittest.cc b/tools/gn/parser_unittest.cc |
index f5adb04ac679e4c269182d50ea2869320f2b0833..39b69b7845c619f1d2709b2ae3330957d7944d69 100644 |
--- a/tools/gn/parser_unittest.cc |
+++ b/tools/gn/parser_unittest.cc |
@@ -181,6 +181,9 @@ TEST(Parser, UnaryOp) { |
DoExpressionPrintTest("!foo", |
"UNARY(!)\n" |
" IDENTIFIER(foo)\n"); |
+ |
+ // No contents for binary operator. |
+ DoExpressionErrorTest("a = !", 1, 5); |
} |
TEST(Parser, List) { |
@@ -215,6 +218,8 @@ TEST(Parser, Assignment) { |
" BINARY(=)\n" |
" IDENTIFIER(a)\n" |
" LITERAL(2)\n"); |
+ |
+ DoExpressionErrorTest("a = ", 1, 3); |
} |
TEST(Parser, Accessor) { |