File tree 2 files changed +19
-4
lines changed
android_tests/lib/android/specs
2 files changed +19
-4
lines changed Original file line number Diff line number Diff line change @@ -63,7 +63,15 @@ def id_value
63
63
t 'find by id' do
64
64
wait { find ( 'accessibility' ) . click }
65
65
wait { find ( 'accessibility node provider' ) . click }
66
- wait { id 'accessibility_node_provider' } # Accessibility/Accessibility Node Provider
66
+
67
+ if !automation_name_is_uiautomator2?
68
+ wait { text 'Accessibility/Accessibility Node Provider' }
69
+ else
70
+ # With string.xml
71
+ # Only for uiautomator1
72
+ wait { id 'accessibility_node_provider' }
73
+ end
74
+
67
75
2 . times { back }
68
76
end
69
77
Original file line number Diff line number Diff line change 48
48
end
49
49
50
50
t 'id success' do
51
- wait do
52
- el = id 'autocomplete_3_button_7' # <string name="autocomplete_3_button_7">Text</string>
53
- el . name . must_equal 'Text'
51
+ if !automation_name_is_uiautomator2?
52
+ wait do
53
+ el = id 'autocomplete_3_button_7' # <string name="autocomplete_3_button_7">Text</string>
54
+ el . name . must_equal 'Text'
55
+ end
56
+ else
57
+ wait do
58
+ el = text 'text' # <string name="autocomplete_3_button_7">Text</string>
59
+ el . name . must_equal 'Text'
60
+ end
54
61
end
55
62
end
56
63
You can’t perform that action at this time.
0 commit comments