Index: test/cctest/test-api.cc |
diff --git a/test/cctest/test-api.cc b/test/cctest/test-api.cc |
index 219059e407c0b88400f674e2f7a3d3ffe498670c..8a3d14c7a0285c2ec4418a398f8a0aa99e687c36 100644 |
--- a/test/cctest/test-api.cc |
+++ b/test/cctest/test-api.cc |
@@ -17483,6 +17483,8 @@ TEST(PersistentHandleInNewSpaceVisitor) { |
TEST(RegExp) { |
+ i::FLAG_harmony_regexps = true; |
+ i::FLAG_harmony_unicode_regexps = true; |
LocalContext context; |
v8::HandleScope scope(context->GetIsolate()); |
@@ -17507,6 +17509,14 @@ TEST(RegExp) { |
CHECK_EQ(v8::RegExp::kIgnoreCase | v8::RegExp::kMultiline, |
static_cast<int>(re->GetFlags())); |
+ re = v8::RegExp::New(v8_str("baz"), |
+ static_cast<v8::RegExp::Flags>(v8::RegExp::kUnicode | |
+ v8::RegExp::kSticky)); |
+ CHECK(re->IsRegExp()); |
+ CHECK(re->GetSource()->Equals(v8_str("baz"))); |
+ CHECK_EQ(v8::RegExp::kUnicode | v8::RegExp::kSticky, |
+ static_cast<int>(re->GetFlags())); |
+ |
re = CompileRun("/quux/").As<v8::RegExp>(); |
CHECK(re->IsRegExp()); |
CHECK(re->GetSource()->Equals(v8_str("quux"))); |