summaryrefslogtreecommitdiffstats
path: root/webkit/mocks
diff options
context:
space:
mode:
authorjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-23 03:08:12 +0000
committerjam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-23 03:08:12 +0000
commitc1978abe9e90c9471994d744bc4f511bc116658d (patch)
treef9cc83b1144ae5dda400142eb55791d039055030 /webkit/mocks
parenta1a6d1788a40095b841794ceb9ed5769523ae867 (diff)
downloadchromium_src-c1978abe9e90c9471994d744bc4f511bc116658d.zip
chromium_src-c1978abe9e90c9471994d744bc4f511bc116658d.tar.gz
chromium_src-c1978abe9e90c9471994d744bc4f511bc116658d.tar.bz2
Convert the remaining test_shell_tests to content_browsertests.
DomOperationsTests.*, DomSerializerTests.* and ResourceFetcherTests.* depended on TestShell loading URLs correctly. That couldn't be done with RenderViewTest harness since ResourceDispatcher code isn't hooked up. I added a mechanism for the browser test harness to run code on the renderer thread when running in --single-process mode. That way a "browser test" can poke at the renderer code. single-process mode doesn't work on Linux Aura, so disabled those tests there for now (bug 234172). DomSerializerTests.* fail on Android. They never ran there before since test_shell_tests never worked there, so just disabled them there with a note to investigate. Note CppBoundClassTest is trivial and doesn't depend on loading, so I just made it a RenderViewTest. I removed plugin_tests.cc: -PluginTest.Refresh won't work with sharding. It's for a use case we don't care much about anyways, so a regression, if it happens, isn't critical. -PluginTest.DeleteFrameDuringEvent is a duplicate of PluginTest.SelfDeletePluginInvokeInSynchronousMouseUp -PluginTest.ForceReload is for in process plugins (i.e. test shell), doesn't apply to our multi-process plugins -PluginTest.PluginVisibilty is currently disabled and failing. I thought about porting it and fixing it, but it seemed low priority since it'd be flaky to test this with our multi-process plugins. This code also doesn't change anymore, and if we had a regression we would catch this pretty quickly. If we regress we can write a test then. mock_spellcheck_unittest.cc: was testing a mock object used in TestShell. Since TestShell is going away, there's no need for this test. if the object breaks and no existing tests break, then it's a non-issue. memory_file_util.cc wasn't used other than in its unittest. I removed the code and its test. CppBoundClassTest.* could be converted to a RenderViewTest. The remaining tests (HostVarTrackerTest.*, papiPluginInstanceTest.*, PpapiCustomInterfaceFactoryTest.*, QuotaFileIOTest.*, WebkitGlueUserAgentTest.* were converted to content_unittests. I will delete the unused webkit/data in a follow up patch (try servers are failing on applying the delete). BUG=126514,234172,111601,51622 Review URL: https://codereview.chromium.org/14304004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@195701 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/mocks')
-rw-r--r--webkit/mocks/mock_resource_loader_bridge.h46
1 files changed, 0 insertions, 46 deletions
diff --git a/webkit/mocks/mock_resource_loader_bridge.h b/webkit/mocks/mock_resource_loader_bridge.h
deleted file mode 100644
index 3af75a7..0000000
--- a/webkit/mocks/mock_resource_loader_bridge.h
+++ /dev/null
@@ -1,46 +0,0 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef WEBKIT_MOCKS_MOCK_RESOURCE_LOADER_BRIDGE_H_
-#define WEBKIT_MOCKS_MOCK_RESOURCE_LOADER_BRIDGE_H_
-
-#include "testing/gmock/include/gmock/gmock.h"
-#include "webkit/glue/resource_loader_bridge.h"
-
-namespace base {
-class FilePath;
-}
-
-namespace webkit_glue {
-
-class MockResourceLoaderBridge : public webkit_glue::ResourceLoaderBridge {
- public:
- MockResourceLoaderBridge() {
- }
-
- virtual ~MockResourceLoaderBridge() {
- OnDestroy();
- }
-
- MOCK_METHOD2(AppendDataToUpload, void(const char* data, int data_len));
- MOCK_METHOD4(AppendFileRangeToUpload,
- void(const base::FilePath& file_path,
- uint64 offset,
- uint64 length,
- const base::Time& expected_modification_time));
- MOCK_METHOD1(AppendBlobToUpload, void(const GURL& blob_url));
- MOCK_METHOD1(SetUploadIdentifier, void(int64 identifier));
- MOCK_METHOD1(Start, bool(ResourceLoaderBridge::Peer* peer));
- MOCK_METHOD0(Cancel, void());
- MOCK_METHOD1(SetDefersLoading, void(bool value));
- MOCK_METHOD1(SyncLoad, void(SyncLoadResponse* response));
- MOCK_METHOD0(OnDestroy, void());
-
- private:
- DISALLOW_COPY_AND_ASSIGN(MockResourceLoaderBridge);
-};
-
-} // namespace webkit_glue
-
-#endif // WEBKIT_MOCKS_MOCK_RESOURCE_LOADER_BRIDGE_H_