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

Side by Side Diff: content/browser/accessibility/android_granularity_movement_browsertest.cc

Issue 1473833002: Fix bugs in accessible name calculation code exposed by Bryan Garaventa's test files. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@dumb_mistake
Patch Set: Fix android test expectation Created 5 years 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 | third_party/WebKit/LayoutTests/accessibility/description-calc-inputs.html » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include <set> 5 #include <set>
6 #include <string> 6 #include <string>
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
197 NavigateByLine) { 197 NavigateByLine) {
198 GURL url("data:text/html," 198 GURL url("data:text/html,"
199 "<body>" 199 "<body>"
200 "<pre>One,%0dtwo,%0dthree!</pre>" 200 "<pre>One,%0dtwo,%0dthree!</pre>"
201 "</body>"); 201 "</body>");
202 BrowserAccessibility* root = LoadUrlAndGetAccessibilityRoot(url); 202 BrowserAccessibility* root = LoadUrlAndGetAccessibilityRoot(url);
203 ASSERT_EQ(1U, root->PlatformChildCount()); 203 ASSERT_EQ(1U, root->PlatformChildCount());
204 BrowserAccessibility* pre = root->PlatformGetChild(0); 204 BrowserAccessibility* pre = root->PlatformGetChild(0);
205 ASSERT_EQ(0U, pre->PlatformChildCount()); 205 ASSERT_EQ(0U, pre->PlatformChildCount());
206 206
207 ASSERT_EQ(base::ASCIIToUTF16("'One, ', 'two, ', 'three!'"), 207 ASSERT_EQ(base::ASCIIToUTF16("'One,', 'two,', 'three!'"),
208 TraverseNodeAtGranularity(pre, GRANULARITY_LINE)); 208 TraverseNodeAtGranularity(pre, GRANULARITY_LINE));
209 } 209 }
210 210
211 } // namespace content 211 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/accessibility/description-calc-inputs.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698