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

Side by Side Diff: components/sessions/serialized_navigation_entry_test_helper.h

Issue 14497003: Moves TabNavigation into components/sessions and renames (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Really remove webkit_support Created 7 years, 7 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
(Empty)
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef COMPONENTS_SESSIONS_SESSION_TYPES_TEST_HELPER_H_
6 #define COMPONENTS_SESSIONS_SESSION_TYPES_TEST_HELPER_H_
7
8 #include <string>
9
10 #include "base/basictypes.h"
11 #include "content/public/common/page_transition_types.h"
12
13 class GURL;
14
15 namespace base {
16 class Time;
17 }
18
19 namespace content {
20 struct Referrer;
21 }
22
23 namespace sessions {
24
25 class SerializedNavigationEntry;
26
27 // Set of test functions to manipulate a SerializedNavigationEntry.
28 class SerializedNavigationEntryTestHelper {
29 public:
30 // Compares the two entries. This uses EXPECT_XXX on each member, if your test
31 // needs to stop after this wrap calls to this in EXPECT_NO_FATAL_FAILURE.
32 static void ExpectNavigationEquals(const SerializedNavigationEntry& expected,
33 const SerializedNavigationEntry& actual);
34
35 // Create a SerializedNavigationEntry with the given URL and title and some
36 // common values for the other fields.
37 static SerializedNavigationEntry CreateNavigation(
38 const std::string& virtual_url,
39 const std::string& title);
40
41 static void SetContentState(const std::string& content_state,
42 SerializedNavigationEntry* navigation);
43
44 static void SetHasPostData(bool has_post_data,
45 SerializedNavigationEntry* navigation);
46
47 static void SetOriginalRequestURL(const GURL& original_request_url,
48 SerializedNavigationEntry* navigation);
49
50 static void SetIsOverridingUserAgent(bool is_overriding_user_agent,
51 SerializedNavigationEntry* navigation);
52
53 static void SetTimestamp(base::Time timestamp,
54 SerializedNavigationEntry* navigation);
55
56 private:
57 DISALLOW_IMPLICIT_CONSTRUCTORS(SerializedNavigationEntryTestHelper);
58 };
59
60 } // sessions
61
62 #endif // COMPONENTS_SESSIONS_SESSION_TYPES_TEST_HELPER_H_
OLDNEW
« no previous file with comments | « components/sessions/serialized_navigation_entry.cc ('k') | components/sessions/serialized_navigation_entry_test_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698