| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "content/test/test_blink_web_unit_test_support.h" | 5 #include "content/test/test_blink_web_unit_test_support.h" |
| 6 | 6 |
| 7 #include "base/feature_list.h" | 7 #include "base/feature_list.h" |
| 8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
| 9 #include "base/files/file_util.h" | 9 #include "base/files/file_util.h" |
| 10 #include "base/files/scoped_temp_dir.h" | 10 #include "base/files/scoped_temp_dir.h" |
| (...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 190 return NULL; | 190 return NULL; |
| 191 } | 191 } |
| 192 | 192 |
| 193 blink::WebMimeRegistry* TestBlinkWebUnitTestSupport::mimeRegistry() { | 193 blink::WebMimeRegistry* TestBlinkWebUnitTestSupport::mimeRegistry() { |
| 194 return &mime_registry_; | 194 return &mime_registry_; |
| 195 } | 195 } |
| 196 | 196 |
| 197 blink::WebURLLoader* TestBlinkWebUnitTestSupport::createURLLoader() { | 197 blink::WebURLLoader* TestBlinkWebUnitTestSupport::createURLLoader() { |
| 198 // This loader should be used only for process-local resources such as | 198 // This loader should be used only for process-local resources such as |
| 199 // data URLs. | 199 // data URLs. |
| 200 blink::WebURLLoader* default_loader = new WebURLLoaderImpl(nullptr, nullptr); | 200 blink::WebURLLoader* default_loader = |
| 201 new WebURLLoaderImpl(nullptr, nullptr, nullptr); |
| 201 return url_loader_factory_->createURLLoader(default_loader); | 202 return url_loader_factory_->createURLLoader(default_loader); |
| 202 } | 203 } |
| 203 | 204 |
| 204 blink::WebString TestBlinkWebUnitTestSupport::userAgent() { | 205 blink::WebString TestBlinkWebUnitTestSupport::userAgent() { |
| 205 return blink::WebString::fromUTF8("test_runner/0.0.0.0"); | 206 return blink::WebString::fromUTF8("test_runner/0.0.0.0"); |
| 206 } | 207 } |
| 207 | 208 |
| 208 std::unique_ptr<cc::SharedBitmap> | 209 std::unique_ptr<cc::SharedBitmap> |
| 209 TestBlinkWebUnitTestSupport::allocateSharedBitmap( | 210 TestBlinkWebUnitTestSupport::allocateSharedBitmap( |
| 210 const blink::WebSize& size) { | 211 const blink::WebSize& size) { |
| (...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 349 blink::WebRTCCertificateGenerator* | 350 blink::WebRTCCertificateGenerator* |
| 350 TestBlinkWebUnitTestSupport::createRTCCertificateGenerator() { | 351 TestBlinkWebUnitTestSupport::createRTCCertificateGenerator() { |
| 351 #if defined(ENABLE_WEBRTC) | 352 #if defined(ENABLE_WEBRTC) |
| 352 return new TestWebRTCCertificateGenerator(); | 353 return new TestWebRTCCertificateGenerator(); |
| 353 #else | 354 #else |
| 354 return nullptr; | 355 return nullptr; |
| 355 #endif | 356 #endif |
| 356 } | 357 } |
| 357 | 358 |
| 358 } // namespace content | 359 } // namespace content |
| OLD | NEW |