Index: third_party/WebKit/Source/bindings/core/v8/ScriptStreamerTest.cpp |
diff --git a/third_party/WebKit/Source/bindings/core/v8/ScriptStreamerTest.cpp b/third_party/WebKit/Source/bindings/core/v8/ScriptStreamerTest.cpp |
index 4056578c8b1ea107e5c049882c9a45125469ae3b..1fc8ec2467dbd15c1704d66fe8036ad0e2a8b98c 100644 |
--- a/third_party/WebKit/Source/bindings/core/v8/ScriptStreamerTest.cpp |
+++ b/third_party/WebKit/Source/bindings/core/v8/ScriptStreamerTest.cpp |
@@ -32,7 +32,7 @@ public: |
, m_scope(v8::Isolate::GetCurrent()) |
, m_settings(Settings::create()) |
, m_resourceRequest("http://www.streaming-test.com/") |
- , m_resource(new ScriptResource(m_resourceRequest, "UTF-8")) |
+ , m_resource(ScriptResource::create(m_resourceRequest, "UTF-8")) |
, m_pendingScript(PendingScript::create(0, m_resource.get())) |
{ |
m_resource->setLoading(true); |
@@ -89,7 +89,7 @@ protected: |
// fetch any data outside the test; the test controls the data by calling |
// ScriptResource::appendData. |
ResourceRequest m_resourceRequest; |
- ResourcePtr<ScriptResource> m_resource; |
+ RefPtrWillBePersistent<ScriptResource> m_resource; |
OwnPtrWillBePersistent<PendingScript> m_pendingScript; |
}; |
@@ -191,10 +191,10 @@ TEST_F(ScriptStreamingTest, CancellingStreaming) |
// Simulate cancelling the network load (e.g., because the user navigated |
// away). |
EXPECT_FALSE(client.finished()); |
- pendingScript()->stopWatchingForLoad(&client); |
+ pendingScript()->stopWatchingForLoad(); |
pendingScript()->releaseElementAndClear(); |
m_pendingScript = nullptr; // This will destroy m_resource. |
- m_resource = 0; |
+ m_resource = nullptr; |
// The V8 side will complete too. This should not crash. We don't receive |
// any results from the streaming and the client doesn't get notified. |