Commit e09772fe authored by Moe Ahmadi's avatar Moe Ahmadi Committed by Commit Bot

[iOS][Translate] Adds EarlGrey tests for the new translate infobar (part 2)

Adds tests for:

1. Auto Always translate (incl. max tries)
2. Never translate language
3. Auto Never translate (incl. max tries)
4. Never translate site


Bug: 910994
Change-Id: Ice90d639afd1f48dbdace62f6da8932f7b78d185
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1521592
Commit-Queue: Moe Ahmadi <mahmadi@chromium.org>
Reviewed-by: default avataranthonyvd <anthonyvd@chromium.org>
Cr-Commit-Position: refs/heads/master@{#642911}
parent c75859d9
......@@ -24,7 +24,6 @@
#include "ui/base/l10n/l10n_util.h"
namespace translate {
namespace {
// The number of times user should consecutively translate for "Always
// Translate" to automatically trigger.
const int kAutoAlwaysThreshold = 5;
......@@ -35,7 +34,6 @@ const int kAutoNeverThreshold = 10;
const int kMaxNumberOfAutoAlways = 2;
// The maximum number of times "Never Translate" is automatically triggered.
const int kMaxNumberOfAutoNever = 2;
} // namespace
const base::Feature kTranslateCompactUI{"TranslateCompactUI",
base::FEATURE_ENABLED_BY_DEFAULT};
......
......@@ -29,6 +29,17 @@ class InfoBarManager;
namespace translate {
// The number of times user should consecutively translate for "Always
// Translate" to automatically trigger.
extern const int kAutoAlwaysThreshold;
// The number of times user should consecutively dismiss the translate infobar
// for "Never Translate" to automatically trigger.
extern const int kAutoNeverThreshold;
// The maximum number of times "Always Translate" is automatically triggered.
extern const int kMaxNumberOfAutoAlways;
// The maximum number of times "Never Translate" is automatically triggered.
extern const int kMaxNumberOfAutoNever;
// Feature flag for "Translate Compact Infobar UI" project.
extern const base::Feature kTranslateCompactUI;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment