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

Side by Side Diff: content/renderer/accessibility/render_accessibility_impl_browsertest.cc

Issue 2694413006: Scope and clean up uses of AccessibilityMode. (Closed)
Patch Set: define konstants Created 3 years, 9 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 <tuple> 5 #include <tuple>
6 6
7 #include "base/macros.h" 7 #include "base/macros.h"
8 #include "base/strings/utf_string_conversions.h" 8 #include "base/strings/utf_string_conversions.h"
9 #include "base/time/time.h" 9 #include "base/time/time.h"
10 #include "build/build_config.h" 10 #include "build/build_config.h"
(...skipping 14 matching lines...) Expand all
25 #include "ui/accessibility/ax_node_data.h" 25 #include "ui/accessibility/ax_node_data.h"
26 26
27 using blink::WebAXObject; 27 using blink::WebAXObject;
28 using blink::WebDocument; 28 using blink::WebDocument;
29 29
30 namespace content { 30 namespace content {
31 31
32 class TestRenderAccessibilityImpl : public RenderAccessibilityImpl { 32 class TestRenderAccessibilityImpl : public RenderAccessibilityImpl {
33 public: 33 public:
34 explicit TestRenderAccessibilityImpl(RenderFrameImpl* render_frame) 34 explicit TestRenderAccessibilityImpl(RenderFrameImpl* render_frame)
35 : RenderAccessibilityImpl(render_frame, ACCESSIBILITY_MODE_COMPLETE) { 35 : RenderAccessibilityImpl(render_frame,
36 } 36 AccessibilityMode::kNativeAPIs |
dmazzoni 2017/03/13 22:18:15 nit: should this be kAccessibilityModeComplete?
dougt 2017/03/14 03:18:23 Done.
37 AccessibilityMode::kWebContents |
38 AccessibilityMode::kInlineTextBoxes |
39 AccessibilityMode::kScreenReader |
40 AccessibilityMode::kHTML) {}
37 41
38 void SendPendingAccessibilityEvents() { 42 void SendPendingAccessibilityEvents() {
39 RenderAccessibilityImpl::SendPendingAccessibilityEvents(); 43 RenderAccessibilityImpl::SendPendingAccessibilityEvents();
40 } 44 }
41 }; 45 };
42 46
43 class RenderAccessibilityImplTest : public RenderViewTest { 47 class RenderAccessibilityImplTest : public RenderViewTest {
44 public: 48 public:
45 RenderAccessibilityImplTest() {} 49 RenderAccessibilityImplTest() {}
46 50
(...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 266
263 ASSERT_EQ(3U, event.update.nodes.size()); 267 ASSERT_EQ(3U, event.update.nodes.size());
264 EXPECT_EQ(node_a.axID(), event.update.node_id_to_clear); 268 EXPECT_EQ(node_a.axID(), event.update.node_id_to_clear);
265 EXPECT_EQ(node_a.axID(), event.update.nodes[0].id); 269 EXPECT_EQ(node_a.axID(), event.update.nodes[0].id);
266 EXPECT_EQ(node_b.axID(), event.update.nodes[1].id); 270 EXPECT_EQ(node_b.axID(), event.update.nodes[1].id);
267 EXPECT_EQ(node_c.axID(), event.update.nodes[2].id); 271 EXPECT_EQ(node_c.axID(), event.update.nodes[2].id);
268 EXPECT_EQ(3, CountAccessibilityNodesSentToBrowser()); 272 EXPECT_EQ(3, CountAccessibilityNodesSentToBrowser());
269 } 273 }
270 274
271 } // namespace content 275 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698