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

Unified Diff: components/autofill/core/browser/payments/payments_service_url_unittest.cc

Issue 1999923002: Move the Google Payments URL functions out of content. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
Index: components/autofill/core/browser/payments/payments_service_url_unittest.cc
diff --git a/components/autofill/content/browser/wallet/wallet_service_url_unittest.cc b/components/autofill/core/browser/payments/payments_service_url_unittest.cc
similarity index 77%
rename from components/autofill/content/browser/wallet/wallet_service_url_unittest.cc
rename to components/autofill/core/browser/payments/payments_service_url_unittest.cc
index c37bb793340b0c03539cf5ca34f8559db119af9b..55aad3974bbdc7fb6fc231b2d29e75cc5f728259 100644
--- a/components/autofill/content/browser/wallet/wallet_service_url_unittest.cc
+++ b/components/autofill/core/browser/payments/payments_service_url_unittest.cc
@@ -3,14 +3,13 @@
// found in the LICENSE file.
#include "base/command_line.h"
-#include "components/autofill/content/browser/wallet/wallet_service_url.h"
+#include "components/autofill/core/browser/payments/payments_service_url.h"
#include "components/autofill/core/common/autofill_switches.h"
-#include "content/public/common/content_switches.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "url/gurl.h"
namespace autofill {
-namespace wallet {
+namespace payments {
namespace {
@@ -20,7 +19,7 @@ bool IsUsingProd() {
}
}
-TEST(WalletServiceSandboxUrl, CheckSandboxUrls) {
+TEST(PaymentsServiceSandboxUrl, CheckSandboxUrls) {
base::CommandLine::ForCurrentProcess()->AppendSwitchASCII(
switches::kWalletServiceUseSandbox, "1");
@@ -31,7 +30,7 @@ TEST(WalletServiceSandboxUrl, CheckSandboxUrls) {
GetManageAddressesUrl(1).spec());
}
-TEST(WalletServiceSandboxUrl, CheckProdUrls) {
+TEST(PaymentsServiceSandboxUrl, CheckProdUrls) {
base::CommandLine::ForCurrentProcess()->AppendSwitchASCII(
switches::kWalletServiceUseSandbox, "0");
@@ -42,26 +41,23 @@ TEST(WalletServiceSandboxUrl, CheckProdUrls) {
}
// Disabling, see http://crbug.com/581880.
-TEST(WalletServiceUrl, DISABLED_DefaultsToProd) {
-#if defined(ENABLE_PROD_WALLET_SERVICE)
+TEST(PaymentsServiceUrl, DISABLED_DefaultsToProd) {
+#if defined(ENABLE_PROD_PAYMENTS_SERVICE)
EXPECT_TRUE(IsUsingProd());
#else
EXPECT_FALSE(IsUsingProd());
#endif
base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
- command_line->AppendSwitch(::switches::kReduceSecurityForTesting);
- EXPECT_FALSE(IsUsingProd());
-
command_line->AppendSwitchASCII(switches::kWalletServiceUseSandbox, "0");
EXPECT_TRUE(IsUsingProd());
}
-TEST(WalletServiceUrl, IsUsingProd) {
+TEST(PaymentsServiceUrl, IsUsingProd) {
base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
command_line->AppendSwitchASCII(switches::kWalletServiceUseSandbox, "1");
EXPECT_FALSE(IsUsingProd());
}
-} // namespace wallet
+} // namespace payments
} // namespace autofill
« no previous file with comments | « components/autofill/core/browser/payments/payments_service_url.cc ('k') | components/autofill/core/common/autofill_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698