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

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

Issue 2006263003: Version 5.0.71.53 (cherry-pick) (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@5.0
Patch Set: Created 4 years, 7 months 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 | « src/js/string.js ('k') | test/mjsunit/regress/regress-seqstrsetchar-ex2.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-strings.cc
diff --git a/test/cctest/test-strings.cc b/test/cctest/test-strings.cc
index e992f33c8bc8aaf91e4951398ff1e70e6851ba0d..770042d8148510feba57502b0c6852f3dccf9860 100644
--- a/test/cctest/test-strings.cc
+++ b/test/cctest/test-strings.cc
@@ -1508,3 +1508,25 @@ TEST(FormatMessage) {
"'arg0' returned for property 'arg1' of object 'arg2' is not a function");
CHECK(String::Equals(result, expected));
}
+
+TEST(Regress609831) {
+ CcTest::InitializeVM();
+ LocalContext context;
+ Isolate* isolate = CcTest::i_isolate();
+ {
+ HandleScope scope(isolate);
+ v8::Local<v8::Value> result = CompileRun(
+ "String.fromCharCode(32, 32, 32, 32, 32, "
+ "32, 32, 32, 32, 32, 32, 32, 32, 32, 32, "
+ "32, 32, 32, 32, 32, 32, 32, 32, 32, 32)");
+ CHECK(v8::Utils::OpenHandle(*result)->IsSeqOneByteString());
+ }
+ {
+ HandleScope scope(isolate);
+ v8::Local<v8::Value> result = CompileRun(
+ "String.fromCharCode(432, 432, 432, 432, 432, "
+ "432, 432, 432, 432, 432, 432, 432, 432, 432, "
+ "432, 432, 432, 432, 432, 432, 432, 432, 432)");
+ CHECK(v8::Utils::OpenHandle(*result)->IsSeqTwoByteString());
+ }
+}
« no previous file with comments | « src/js/string.js ('k') | test/mjsunit/regress/regress-seqstrsetchar-ex2.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698