Move a passing test from Errors to MultipleOutputs
authorQingning Huo <qingninghuo@gmail.com>
Tue, 6 Sep 2011 21:19:45 +0000 (22:19 +0100)
committerQingning Huo <qingninghuo@gmail.com>
Tue, 6 Sep 2011 21:19:45 +0000 (22:19 +0100)
src/parsers_test.cc

index 12f09b0..5e2746d 100644 (file)
@@ -316,16 +316,6 @@ TEST_F(ParserTest, Errors) {
     State state;
     ManifestParser parser(&state, NULL);
     string err;
-    EXPECT_TRUE(parser.Parse("rule cc\n  command = foo\n  depfile = bar\n"
-                              "build a.o b.o: cc c.cc\n",
-                              &err));
-    EXPECT_EQ("", err);
-  }
-
-  {
-    State state;
-    ManifestParser parser(&state, NULL);
-    string err;
     EXPECT_FALSE(parser.Parse("rule cc\n  command = foo\n  othervar = bar\n",
                               &err));
     EXPECT_EQ("line 3, col 3: unexpected variable 'othervar'", err);
@@ -371,6 +361,17 @@ TEST_F(ParserTest, Errors) {
   }
 }
 
+TEST_F(ParserTest, MultipleOutputs)
+{
+  State state;
+  ManifestParser parser(&state, NULL);
+  string err;
+  EXPECT_TRUE(parser.Parse("rule cc\n  command = foo\n  depfile = bar\n"
+                            "build a.o b.o: cc c.cc\n",
+                            &err));
+  EXPECT_EQ("", err);
+}
+
 TEST_F(ParserTest, SubNinja) {
   files_["test.ninja"] =
     "var = inner\n"