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

Side by Side Diff: chrome/test/live_sync/live_bookmarks_sync_test.h

Issue 525079: Add autodetection of "intranet" redirection, for ISPs etc. that send typos an... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 11 months 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
OLDNEW
1 // Copyright (c) 2006-2009 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 #ifndef CHROME_TEST_LIVE_SYNC_LIVE_BOOKMARKS_SYNC_TEST_H_ 5 #ifndef CHROME_TEST_LIVE_SYNC_LIVE_BOOKMARKS_SYNC_TEST_H_
6 #define CHROME_TEST_LIVE_SYNC_LIVE_BOOKMARKS_SYNC_TEST_H_ 6 #define CHROME_TEST_LIVE_SYNC_LIVE_BOOKMARKS_SYNC_TEST_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
11 #include "chrome/common/chrome_paths.h" 11 #include "chrome/common/chrome_paths.h"
12 #include "chrome/common/chrome_switches.h" 12 #include "chrome/common/chrome_switches.h"
13 #include "chrome/test/in_process_browser_test.h" 13 #include "chrome/test/in_process_browser_test.h"
14 #include "googleurl/src/gurl.h" 14 #include "googleurl/src/gurl.h"
15 15
16 class BookmarkModel; 16 class BookmarkModel;
17 class BookmarkNode; 17 class BookmarkNode;
18 class Profile; 18 class Profile;
19 namespace net {
20 class ScopedDefaultHostResolverProc;
21 }
19 22
20 namespace switches { 23 namespace switches {
21 extern const wchar_t kSyncUserForTest[]; 24 extern const wchar_t kSyncUserForTest[];
22 extern const wchar_t kSyncPasswordForTest[]; 25 extern const wchar_t kSyncPasswordForTest[];
23 } 26 }
24 27
25 // TODO(timsteele): This should be moved out of personalization_unit_tests into 28 // TODO(timsteele): This should be moved out of personalization_unit_tests into
26 // its own project that doesn't get run by default on the standard buildbot 29 // its own project that doesn't get run by default on the standard buildbot
27 // without a valid sync server set up. 30 // without a valid sync server set up.
28 class LiveBookmarksSyncTest : public InProcessBrowserTest { 31 class LiveBookmarksSyncTest : public InProcessBrowserTest {
29 public: 32 public:
30 LiveBookmarksSyncTest() { } 33 LiveBookmarksSyncTest();
31 ~LiveBookmarksSyncTest() { } 34 ~LiveBookmarksSyncTest();
32 35
33 virtual void SetUp() { 36 virtual void SetUp() {
34 // At this point, the browser hasn't been launched, and no services are 37 // At this point, the browser hasn't been launched, and no services are
35 // available. But we can verify our command line parameters and fail 38 // available. But we can verify our command line parameters and fail
36 // early. 39 // early.
37 const CommandLine* cl = CommandLine::ForCurrentProcess(); 40 const CommandLine* cl = CommandLine::ForCurrentProcess();
38 username_ = WideToUTF8(cl->GetSwitchValue(switches::kSyncUserForTest)); 41 username_ = WideToUTF8(cl->GetSwitchValue(switches::kSyncUserForTest));
39 password_ = WideToUTF8(cl->GetSwitchValue(switches::kSyncPasswordForTest)); 42 password_ = WideToUTF8(cl->GetSwitchValue(switches::kSyncPasswordForTest));
40 ASSERT_FALSE(username_.empty()) << "Can't run live server test " 43 ASSERT_FALSE(username_.empty()) << "Can't run live server test "
41 << "without specifying --" << switches::kSyncUserForTest; 44 << "without specifying --" << switches::kSyncUserForTest;
(...skipping 30 matching lines...) Expand all
72 private: 75 private:
73 // LiveBookmarksSyncTests need to make live DNS requests for access to 76 // LiveBookmarksSyncTests need to make live DNS requests for access to
74 // GAIA and sync server URLs under google.com. We use a scoped version 77 // GAIA and sync server URLs under google.com. We use a scoped version
75 // to override the default resolver while the test is active. 78 // to override the default resolver while the test is active.
76 scoped_ptr<net::ScopedDefaultHostResolverProc> mock_host_resolver_override_; 79 scoped_ptr<net::ScopedDefaultHostResolverProc> mock_host_resolver_override_;
77 80
78 DISALLOW_COPY_AND_ASSIGN(LiveBookmarksSyncTest); 81 DISALLOW_COPY_AND_ASSIGN(LiveBookmarksSyncTest);
79 }; 82 };
80 83
81 #endif // CHROME_TEST_LIVE_SYNC_LIVE_BOOKMARKS_SYNC_TEST_H_ 84 #endif // CHROME_TEST_LIVE_SYNC_LIVE_BOOKMARKS_SYNC_TEST_H_
OLDNEW
« no previous file with comments | « chrome/test/in_process_browser_test.cc ('k') | chrome/test/live_sync/live_bookmarks_sync_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698