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

Side by Side Diff: chrome/browser/instant/instant_loader_manager_unittest.cc

Issue 5720002: Merge 68816 - Fixes bug where we would show an instant preview when we though... (Closed) Base URL: svn://svn.chromium.org/chrome/branches/597/src/
Patch Set: Created 10 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/instant/instant_loader_delegate.h ('k') | chrome/test/data/instant/empty.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "base/scoped_ptr.h" 5 #include "base/scoped_ptr.h"
6 #include "chrome/browser/instant/instant_loader.h" 6 #include "chrome/browser/instant/instant_loader.h"
7 #include "chrome/browser/instant/instant_loader_delegate.h" 7 #include "chrome/browser/instant/instant_loader_delegate.h"
8 #include "chrome/browser/instant/instant_loader_manager.h" 8 #include "chrome/browser/instant/instant_loader_manager.h"
9 #include "testing/gtest/include/gtest/gtest.h" 9 #include "testing/gtest/include/gtest/gtest.h"
10 10
(...skipping 12 matching lines...) Expand all
23 return gfx::Rect(); 23 return gfx::Rect();
24 } 24 }
25 25
26 virtual bool ShouldCommitInstantOnMouseUp() { 26 virtual bool ShouldCommitInstantOnMouseUp() {
27 return false; 27 return false;
28 } 28 }
29 29
30 virtual void CommitInstantLoader(InstantLoader* loader) { 30 virtual void CommitInstantLoader(InstantLoader* loader) {
31 } 31 }
32 32
33 virtual void InstantLoaderDoesntSupportInstant(InstantLoader* loader, 33 virtual void InstantLoaderDoesntSupportInstant(InstantLoader* loader) {
34 bool needs_reload,
35 const GURL& url_to_load) {
36 } 34 }
37 35
38 virtual void AddToBlacklist(InstantLoader* loader, const GURL& url) { 36 virtual void AddToBlacklist(InstantLoader* loader, const GURL& url) {
39 } 37 }
40 38
41 private: 39 private:
42 DISALLOW_COPY_AND_ASSIGN(InstantLoaderDelegateImpl); 40 DISALLOW_COPY_AND_ASSIGN(InstantLoaderDelegateImpl);
43 }; 41 };
44 42
45 } 43 }
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after
270 EXPECT_TRUE(manager.WillUpateChangeActiveLoader(1)); 268 EXPECT_TRUE(manager.WillUpateChangeActiveLoader(1));
271 ASSERT_TRUE(manager.active_loader()); 269 ASSERT_TRUE(manager.active_loader());
272 MarkReady(manager.active_loader()); 270 MarkReady(manager.active_loader());
273 271
274 // Add a loader with id 1 and test again. 272 // Add a loader with id 1 and test again.
275 manager.UpdateLoader(1, &loader); 273 manager.UpdateLoader(1, &loader);
276 EXPECT_TRUE(manager.WillUpateChangeActiveLoader(0)); 274 EXPECT_TRUE(manager.WillUpateChangeActiveLoader(0));
277 EXPECT_FALSE(manager.WillUpateChangeActiveLoader(1)); 275 EXPECT_FALSE(manager.WillUpateChangeActiveLoader(1));
278 } 276 }
279 277
OLDNEW
« no previous file with comments | « chrome/browser/instant/instant_loader_delegate.h ('k') | chrome/test/data/instant/empty.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698