@@ -109,17 +109,17 @@ public class AndroidGestureTest extends BaseAndroidTest {
109
109
}
110
110
111
111
@ Test public void verticalSwipingTest () throws Exception {
112
- driver .startActivity ( "io.appium.android.apis" , ".view.DateWidgets2" );
113
- AndroidElement numberPicker = driver .findElementByClassName ("android.widget.NumberPicker " );
114
- MobileElement numberInput = numberPicker .findElementById ("android:id/numberpicker_input " );
112
+ driver .findElementByAccessibilityId ( "Views" ). click ( );
113
+ AndroidElement listView = driver .findElementByClassName ("android.widget.ListView " );
114
+ MobileElement textView = driver .findElementById ("android:id/text1 " );
115
115
116
- String originalNumber = numberInput .getText ();
116
+ String originalText = textView .getText ();
117
117
118
- numberPicker .swipe (SwipeElementDirection .UP , 20 , 10 , 1000 );
119
- assertNotEquals (originalNumber , numberInput .getText ());
118
+ listView .swipe (SwipeElementDirection .UP , 20 , 15 , 1000 );
119
+ assertNotEquals (originalText , textView .getText ());
120
120
121
- numberPicker .swipe (SwipeElementDirection .DOWN , 20 , 10 , 1000 );
122
- assertEquals (originalNumber , numberInput .getText ());
121
+ listView .swipe (SwipeElementDirection .DOWN , 20 , 15 , 1000 );
122
+ assertEquals (originalText , textView .getText ());
123
123
}
124
124
125
125
@ Test public void horizontalSwipingTest () throws Exception {
0 commit comments