Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(241)

Unified Diff: test/cctest/test-parsing.cc

Issue 766673003: Make the ParserSync test faster (and re-enable it). (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-parsing.cc
diff --git a/test/cctest/test-parsing.cc b/test/cctest/test-parsing.cc
index 4e2f828a60c3c660edf7bef7d6814d74dd9ec06b..d1822fa3ca4d3fa03c1d5c027ed76a807b922667 100644
--- a/test/cctest/test-parsing.cc
+++ b/test/cctest/test-parsing.cc
@@ -1519,9 +1519,7 @@ void TestParserSync(const char* source,
}
-// TODO(marja) This needs to be turned into a fuzzing test, trying all those
-// combinations below takes at least 2 orders of magnitude too long.
-DISABLED_TEST(ParserSync) {
+TEST(ParserSync) {
const char* context_data[][2] = {
{ "", "" },
{ "{", "}" },
@@ -1550,7 +1548,7 @@ DISABLED_TEST(ParserSync) {
"if (false) {} else ;",
"if (false) {} else {}",
"if (false) {} else 12",
- "if (false) ;"
+ "if (false) ;",
"if (false) {}",
"if (false) 12",
"do {} while (false)",
@@ -1570,8 +1568,8 @@ DISABLED_TEST(ParserSync) {
"with ({}) ;",
"with ({}) {}",
"with ({}) 12",
- "switch ({}) { default: }"
- "label3: "
+ "switch ({}) { default: }",
+ "label3: ",
"throw",
"throw 12",
"throw\n12",
@@ -1598,17 +1596,6 @@ DISABLED_TEST(ParserSync) {
CcTest::i_isolate()->stack_guard()->SetStackLimit(
i::GetCurrentStackPosition() - 128 * 1024);
- static const ParserFlag flags1[] = {
- kAllowHarmonyArrowFunctions,
- kAllowHarmonyClasses,
- kAllowHarmonyNumericLiterals,
- kAllowHarmonyObjectLiterals,
- kAllowHarmonyScoping,
- kAllowHarmonyModules,
- kAllowHarmonySloppy,
- kAllowLazy,
- };
-
for (int i = 0; context_data[i][0] != NULL; ++i) {
for (int j = 0; statement_data[j] != NULL; ++j) {
for (int k = 0; termination_data[k] != NULL; ++k) {
@@ -1628,7 +1615,7 @@ DISABLED_TEST(ParserSync) {
termination_data[k],
context_data[i][1]);
CHECK(length == kProgramSize);
- TestParserSync(program.start(), flags1, arraysize(flags1));
+ TestParserSync(program.start(), NULL, 0);
}
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698