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

Unified Diff: third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueSerializerTest.cpp

Issue 2554693003: Migrate WTF::Vector::append() to ::push_back() [part 1 of N] (Closed)
Patch Set: rebase Created 4 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
Index: third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueSerializerTest.cpp
diff --git a/third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueSerializerTest.cpp b/third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueSerializerTest.cpp
index 1568332b39b94dd74d8f7288b6088919e0b4779a..26b1d6fbedb91f92d1ffc8b3b1c2b23e6902934b 100644
--- a/third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueSerializerTest.cpp
+++ b/third_party/WebKit/Source/bindings/core/v8/serialization/V8ScriptValueSerializerTest.cpp
@@ -211,7 +211,7 @@ TEST(V8ScriptValueSerializerTest, NeuteringHappensAfterSerialization) {
ASSERT_FALSE(arrayBuffer->isNeutered());
v8::Local<v8::Value> object = eval("({ get a() { throw 'party'; }})", scope);
Transferables transferables;
- transferables.arrayBuffers.append(arrayBuffer);
+ transferables.arrayBuffers.push_back(arrayBuffer);
roundTrip(object, scope, &exceptionState, &transferables);
ASSERT_TRUE(exceptionState.hadException());
@@ -289,7 +289,7 @@ TEST(V8ScriptValueSerializerTest, RoundTripMessagePort) {
makeMessagePort(scope.getExecutionContext(), &unownedChannel);
v8::Local<v8::Value> wrapper = toV8(port, scope.getScriptState());
Transferables transferables;
- transferables.messagePorts.append(port);
+ transferables.messagePorts.push_back(port);
v8::Local<v8::Value> result =
roundTrip(wrapper, scope, nullptr, &transferables);
@@ -311,7 +311,7 @@ TEST(V8ScriptValueSerializerTest, NeuteredMessagePortThrowsDataCloneError) {
EXPECT_TRUE(port->isNeutered());
v8::Local<v8::Value> wrapper = toV8(port, scope.getScriptState());
Transferables transferables;
- transferables.messagePorts.append(port);
+ transferables.messagePorts.push_back(port);
roundTrip(wrapper, scope, &exceptionState, &transferables);
ASSERT_TRUE(hadDOMException("DataCloneError", scope.getScriptState(),
@@ -356,15 +356,15 @@ TEST(V8ScriptValueSerializerTest, OutOfRangeMessagePortIndex) {
}
{
MessagePortArray* ports = new MessagePortArray;
- ports->append(port1);
+ ports->push_back(port1);
V8ScriptValueDeserializer deserializer(scriptState, input);
deserializer.setTransferredMessagePorts(ports);
ASSERT_TRUE(deserializer.deserialize()->IsNull());
}
{
MessagePortArray* ports = new MessagePortArray;
- ports->append(port1);
- ports->append(port2);
+ ports->push_back(port1);
+ ports->push_back(port2);
V8ScriptValueDeserializer deserializer(scriptState, input);
deserializer.setTransferredMessagePorts(ports);
v8::Local<v8::Value> result = deserializer.deserialize();
@@ -489,7 +489,7 @@ TEST(V8ScriptValueSerializerTest, TransferImageBitmap) {
v8::Local<v8::Value> wrapper = toV8(imageBitmap, scope.getScriptState());
Transferables transferables;
- transferables.imageBitmaps.append(imageBitmap);
+ transferables.imageBitmaps.push_back(imageBitmap);
v8::Local<v8::Value> result =
roundTrip(wrapper, scope, nullptr, &transferables);
ASSERT_TRUE(V8ImageBitmap::hasInstance(result, scope.isolate()));
@@ -518,7 +518,7 @@ TEST(V8ScriptValueSerializerTest, TransferOffscreenCanvas) {
canvas->setPlaceholderCanvasId(519);
v8::Local<v8::Value> wrapper = toV8(canvas, scope.getScriptState());
Transferables transferables;
- transferables.offscreenCanvases.append(canvas);
+ transferables.offscreenCanvases.push_back(canvas);
v8::Local<v8::Value> result =
roundTrip(wrapper, scope, nullptr, &transferables);
ASSERT_TRUE(V8OffscreenCanvas::hasInstance(result, scope.isolate()));

Powered by Google App Engine
This is Rietveld 408576698