summaryrefslogtreecommitdiffstats
path: root/chrome/browser/rlz/rlz_unittest.cc
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/rlz/rlz_unittest.cc')
-rw-r--r--chrome/browser/rlz/rlz_unittest.cc39
1 files changed, 20 insertions, 19 deletions
diff --git a/chrome/browser/rlz/rlz_unittest.cc b/chrome/browser/rlz/rlz_unittest.cc
index 165652f..8693091 100644
--- a/chrome/browser/rlz/rlz_unittest.cc
+++ b/chrome/browser/rlz/rlz_unittest.cc
@@ -96,6 +96,7 @@ AssertionResult CmpHelperSTRNC(const char* str_expression,
// overrides others to make it easier to test.
class TestRLZTracker : public RLZTracker {
public:
+ using RLZTracker::InitRlzDelayed;
using RLZTracker::DelayedInit;
using RLZTracker::Observe;
@@ -389,7 +390,7 @@ TEST_F(RlzLibTest, RecordProductEvent) {
}
TEST_F(RlzLibTest, QuickStopAfterStart) {
- RLZTracker::InitRlzDelayed(true, 20, true, true, true);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, true);
// Omnibox events.
ExpectEventRecorded(kOmniboxInstall, false);
@@ -405,7 +406,7 @@ TEST_F(RlzLibTest, QuickStopAfterStart) {
}
TEST_F(RlzLibTest, DelayedInitOnly) {
- RLZTracker::InitRlzDelayed(true, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, false);
InvokeDelayedInit();
// Omnibox events.
@@ -422,7 +423,7 @@ TEST_F(RlzLibTest, DelayedInitOnly) {
}
TEST_F(RlzLibTest, DelayedInitOnlyGoogleAsStartup) {
- RLZTracker::InitRlzDelayed(true, 20, false, false, true);
+ TestRLZTracker::InitRlzDelayed(true, 20, false, false, true);
InvokeDelayedInit();
// Omnibox events.
@@ -439,7 +440,7 @@ TEST_F(RlzLibTest, DelayedInitOnlyGoogleAsStartup) {
}
TEST_F(RlzLibTest, DelayedInitOnlyNoFirstRunNoRlzStrings) {
- RLZTracker::InitRlzDelayed(false, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(false, 20, true, true, false);
InvokeDelayedInit();
// Omnibox events.
@@ -456,7 +457,7 @@ TEST_F(RlzLibTest, DelayedInitOnlyNoFirstRunNoRlzStrings) {
}
TEST_F(RlzLibTest, DelayedInitOnlyNoFirstRunNoRlzStringsGoogleAsStartup) {
- RLZTracker::InitRlzDelayed(false, 20, false, false, true);
+ TestRLZTracker::InitRlzDelayed(false, 20, false, false, true);
InvokeDelayedInit();
// Omnibox events.
@@ -478,7 +479,7 @@ TEST_F(RlzLibTest, DelayedInitOnlyNoFirstRun) {
rlz_lib::SetAccessPointRlz(RLZTracker::CHROME_OMNIBOX, kOmniboxRlzString);
rlz_lib::SetAccessPointRlz(RLZTracker::CHROME_HOME_PAGE, kHomepageRlzString);
- RLZTracker::InitRlzDelayed(false, 20, true, true, true);
+ TestRLZTracker::InitRlzDelayed(false, 20, true, true, true);
InvokeDelayedInit();
// Omnibox events.
@@ -495,7 +496,7 @@ TEST_F(RlzLibTest, DelayedInitOnlyNoFirstRun) {
}
TEST_F(RlzLibTest, DelayedInitOnlyNoGoogleDefaultSearchOrHomepageOrStartup) {
- RLZTracker::InitRlzDelayed(true, 20, false, false, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, false, false, false);
InvokeDelayedInit();
// Omnibox events.
@@ -512,7 +513,7 @@ TEST_F(RlzLibTest, DelayedInitOnlyNoGoogleDefaultSearchOrHomepageOrStartup) {
}
TEST_F(RlzLibTest, OmniboxUsageOnly) {
- RLZTracker::InitRlzDelayed(true, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, false);
SimulateOmniboxUsage();
// Omnibox events.
@@ -529,7 +530,7 @@ TEST_F(RlzLibTest, OmniboxUsageOnly) {
}
TEST_F(RlzLibTest, HomepageUsageOnly) {
- RLZTracker::InitRlzDelayed(true, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, false);
SimulateHomepageUsage();
// Omnibox events.
@@ -546,7 +547,7 @@ TEST_F(RlzLibTest, HomepageUsageOnly) {
}
TEST_F(RlzLibTest, UsageBeforeDelayedInit) {
- RLZTracker::InitRlzDelayed(true, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, false);
SimulateOmniboxUsage();
SimulateHomepageUsage();
InvokeDelayedInit();
@@ -565,7 +566,7 @@ TEST_F(RlzLibTest, UsageBeforeDelayedInit) {
}
TEST_F(RlzLibTest, OmniboxUsageAfterDelayedInit) {
- RLZTracker::InitRlzDelayed(true, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, false);
InvokeDelayedInit();
SimulateOmniboxUsage();
SimulateHomepageUsage();
@@ -584,7 +585,7 @@ TEST_F(RlzLibTest, OmniboxUsageAfterDelayedInit) {
}
TEST_F(RlzLibTest, OmniboxUsageSendsPingWhenDelayNegative) {
- RLZTracker::InitRlzDelayed(true, -20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, -20, true, true, false);
SimulateOmniboxUsage();
// Omnibox events.
@@ -601,7 +602,7 @@ TEST_F(RlzLibTest, OmniboxUsageSendsPingWhenDelayNegative) {
}
TEST_F(RlzLibTest, HomepageUsageDoesNotSendPingWhenDelayNegative) {
- RLZTracker::InitRlzDelayed(true, -20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, -20, true, true, false);
SimulateHomepageUsage();
// Omnibox events.
@@ -618,7 +619,7 @@ TEST_F(RlzLibTest, HomepageUsageDoesNotSendPingWhenDelayNegative) {
}
TEST_F(RlzLibTest, StartupUsageDoesNotSendPingWhenDelayNegative) {
- RLZTracker::InitRlzDelayed(true, -20, true, false, true);
+ TestRLZTracker::InitRlzDelayed(true, -20, true, false, true);
SimulateHomepageUsage();
// Omnibox events.
@@ -700,7 +701,7 @@ TEST_F(RlzLibTest, PingUpdatesRlzCache) {
// Perform ping.
tracker_.set_assume_not_ui_thread(true);
- RLZTracker::InitRlzDelayed(true, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, false);
InvokeDelayedInit();
ExpectRlzPingSent(true);
@@ -731,7 +732,7 @@ TEST_F(RlzLibTest, ObserveHandlesBadArgs) {
TEST_F(RlzLibTest, ReactivationNonOrganicNonOrganic) {
SetReactivationBrand("REAC");
- RLZTracker::InitRlzDelayed(true, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, false);
InvokeDelayedInit();
ExpectRlzPingSent(true);
@@ -742,7 +743,7 @@ TEST_F(RlzLibTest, ReactivationOrganicNonOrganic) {
SetMainBrand("GGLS");
SetReactivationBrand("REAC");
- RLZTracker::InitRlzDelayed(true, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, false);
InvokeDelayedInit();
ExpectRlzPingSent(false);
@@ -753,7 +754,7 @@ TEST_F(RlzLibTest, ReactivationNonOrganicOrganic) {
SetMainBrand("TEST");
SetReactivationBrand("GGLS");
- RLZTracker::InitRlzDelayed(true, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, false);
InvokeDelayedInit();
ExpectRlzPingSent(true);
@@ -764,7 +765,7 @@ TEST_F(RlzLibTest, ReactivationOrganicOrganic) {
SetMainBrand("GGLS");
SetReactivationBrand("GGRS");
- RLZTracker::InitRlzDelayed(true, 20, true, true, false);
+ TestRLZTracker::InitRlzDelayed(true, 20, true, true, false);
InvokeDelayedInit();
ExpectRlzPingSent(false);