Index: test/cctest/test-api.cc |
diff --git a/test/cctest/test-api.cc b/test/cctest/test-api.cc |
index 3ed6b523f0ead3b11453c4e36e0aa23c6b0c2511..e206bb9ac366f3ed1ade216406cf9914410b6ca0 100644 |
--- a/test/cctest/test-api.cc |
+++ b/test/cctest/test-api.cc |
@@ -13693,6 +13693,9 @@ THREADED_TEST(TwoByteStringInAsciiCons) { |
"str2;"; |
Local<Value> result = CompileRun(init_code); |
+ Local<Value> indexof = CompileRun("str2.indexOf('els')"); |
+ Local<Value> lastindexof = CompileRun("str2.lastIndexOf('dab')"); |
+ |
CHECK(result->IsString()); |
i::Handle<i::String> string = v8::Utils::OpenHandle(String::Cast(*result)); |
int length = string->length(); |
@@ -13758,6 +13761,10 @@ THREADED_TEST(TwoByteStringInAsciiCons) { |
ExpectString("str2.charAt(2);", "e"); |
+ ExpectObject("str2.indexOf('els');", indexof); |
+ |
+ ExpectObject("str2.lastIndexOf('dab');", lastindexof); |
+ |
reresult = CompileRun("str2.charCodeAt(2);"); |
CHECK_EQ(static_cast<int32_t>('e'), reresult->Int32Value()); |
} |