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

Side by Side Diff: ios/chrome/browser/translate/translate_egtest.mm

Issue 2936693003: Disable TranslateTestCase.testAutoTranslate. (Closed)
Patch Set: Created 3 years, 6 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #import <XCTest/XCTest.h> 5 #import <XCTest/XCTest.h>
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/mac/bind_objc_block.h" 8 #include "base/mac/bind_objc_block.h"
9 #include "base/strings/stringprintf.h" 9 #include "base/strings/stringprintf.h"
10 #include "base/strings/sys_string_conversions.h" 10 #include "base/strings/sys_string_conversions.h"
(...skipping 709 matching lines...) Expand 10 before | Expand all | Expand 10 after
720 [self simulateTranslationFromSpanishToEnglish]; 720 [self simulateTranslationFromSpanishToEnglish];
721 // Check that the infobar does not contain the "Always Translate" switch. 721 // Check that the infobar does not contain the "Always Translate" switch.
722 NSString* switchLabel = GetTranslateInfobarSwitchLabel("Spanish"); 722 NSString* switchLabel = GetTranslateInfobarSwitchLabel("Spanish");
723 [[EarlGrey 723 [[EarlGrey
724 selectElementWithMatcher:chrome_test_util::ButtonWithAccessibilityLabel( 724 selectElementWithMatcher:chrome_test_util::ButtonWithAccessibilityLabel(
725 switchLabel)] assertWithMatcher:grey_nil()]; 725 switchLabel)] assertWithMatcher:grey_nil()];
726 } 726 }
727 727
728 // Tests that translation occurs automatically on second navigation to an 728 // Tests that translation occurs automatically on second navigation to an
729 // already translated page. 729 // already translated page.
730 - (void)testAutoTranslate { 730 // TODO(crbug.com/732797): Reenable this test.
731 - (void)DISABLED_testAutoTranslate {
731 // The translate machinery will not auto-fire without API keys, unless that 732 // The translate machinery will not auto-fire without API keys, unless that
732 // behavior is overridden for testing. 733 // behavior is overridden for testing.
733 translate::TranslateManager::SetIgnoreMissingKeyForTesting(true); 734 translate::TranslateManager::SetIgnoreMissingKeyForTesting(true);
734 735
735 std::unique_ptr<web::DataResponseProvider> provider(new TestResponseProvider); 736 std::unique_ptr<web::DataResponseProvider> provider(new TestResponseProvider);
736 web::test::SetUpHttpServer(std::move(provider)); 737 web::test::SetUpHttpServer(std::move(provider));
737 738
738 // Reset translate prefs to default. 739 // Reset translate prefs to default.
739 std::unique_ptr<translate::TranslatePrefs> translatePrefs( 740 std::unique_ptr<translate::TranslatePrefs> translatePrefs(
740 ChromeIOSTranslateClient::CreateTranslatePrefs( 741 ChromeIOSTranslateClient::CreateTranslatePrefs(
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
846 [[EarlGrey 847 [[EarlGrey
847 selectElementWithMatcher:chrome_test_util::ButtonWithAccessibilityLabelId( 848 selectElementWithMatcher:chrome_test_util::ButtonWithAccessibilityLabelId(
848 IDS_TRANSLATE_INFOBAR_REVERT)] 849 IDS_TRANSLATE_INFOBAR_REVERT)]
849 assertWithMatcher:grey_notNil()]; 850 assertWithMatcher:grey_notNil()];
850 [[EarlGrey 851 [[EarlGrey
851 selectElementWithMatcher:chrome_test_util::ButtonWithAccessibilityLabelId( 852 selectElementWithMatcher:chrome_test_util::ButtonWithAccessibilityLabelId(
852 IDS_CLOSE)] assertWithMatcher:grey_notNil()]; 853 IDS_CLOSE)] assertWithMatcher:grey_notNil()];
853 } 854 }
854 855
855 @end 856 @end
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698