-
Notifications
You must be signed in to change notification settings - Fork 900
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
auditors: @bridiver, @bbondy, @diracdeltas, @bsclifton
- Loading branch information
Showing
5 changed files
with
59 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
chromium_src/components/omnibox/browser/location_bar_model_impl.cc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/* Copyright (c) 2019 The Brave Authors. All rights reserved. | ||
* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this file, | ||
* You can obtain one at http://mozilla.org/MPL/2.0/. */ | ||
|
||
#include "components/omnibox/browser/location_bar_model_impl.h" | ||
|
||
#include "components/omnibox/browser/omnibox_field_trial.h" | ||
|
||
#define GetFieldTrialParamValueByFeature \ | ||
GetFieldTrialParamValueByFeature_ChromiumImpl | ||
|
||
namespace base { | ||
std::string GetFieldTrialParamValueByFeature(const base::Feature& feature, | ||
const std::string& param_name) { | ||
return OmniboxFieldTrial::kSimplifyHttpsIndicatorParameterBothToLock; | ||
} | ||
} // namespace base | ||
|
||
#include "../../../../../../../components/omnibox/browser/location_bar_model_impl.cc" // NOLINT | ||
|
||
#undef GetFieldTrialParamValueByFeature |
20 changes: 20 additions & 0 deletions
20
chromium_src/components/variations/service/field_trial_unittest.cc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
/* Copyright (c) 2019 The Brave Authors. All rights reserved. | ||
* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this file, | ||
* You can obtain one at http://mozilla.org/MPL/2.0/. */ | ||
|
||
#include "components/variations/service/buildflags.h" | ||
#include "testing/gtest/include/gtest/gtest.h" | ||
|
||
namespace { | ||
typedef testing::Test FieldTrialsTest; | ||
|
||
TEST_F(FieldTrialsTest, FieldTrialsTestingEnabled) { | ||
bool enabled = false; | ||
#if BUILDFLAG(FIELDTRIAL_TESTING_ENABLED) | ||
enabled = true | ||
#endif // BUILDFLAG(FIELDTRIAL_TESTING_ENABLED) | ||
EXPECT_FALSE(enabled); | ||
} | ||
|
||
} // namespace |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
diff --git a/components/variations/service/BUILD.gn b/components/variations/service/BUILD.gn | ||
index bdabd37ad8d0f98aad110d68f8058885d3f3c31a..98864341b6223ca591bcd19dc9097d1b6fb829b0 100644 | ||
--- a/components/variations/service/BUILD.gn | ||
+++ b/components/variations/service/BUILD.gn | ||
@@ -11,7 +11,7 @@ declare_args() { | ||
# Note: this setting is ignored if is_chrome_branded. | ||
# TODO(thakis): It's strange this is called "_like_official_build" but then | ||
# checks is_chrome_branded, not is_official_build. | ||
- fieldtrial_testing_like_official_build = is_chrome_branded | ||
+ fieldtrial_testing_like_official_build = true | ||
} | ||
|
||
fieldtrial_testing_enabled = |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters