add all reproduction scripts
This commit is contained in:
parent
59993a8e2e
commit
2398b0680d
|
@ -10,13 +10,51 @@ def wait(seconds=2):
|
|||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
def enAbleDontKeepA(d):
|
||||
d.press("home")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.android.launcher3:id/layout").child(index="1").child(index="2").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Search Apps…").set_text("Settings")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.android.launcher3:id/icon", text="Settings").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(description="Search settings").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Search…").set_text("keep activities")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Don’t keep activities").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Don’t keep activities").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
d.shell("settings put global always_finish_activities 1")
|
||||
enAbleDontKeepA(d)
|
||||
|
||||
d.app_start("com.ichi2.anki")
|
||||
wait()
|
||||
|
@ -85,7 +123,7 @@ if __name__ == '__main__':
|
|||
print("Success: press save")
|
||||
wait()
|
||||
|
||||
d.shell("settings put global always_finish_activities 0")
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
|
|
|
@ -11,12 +11,52 @@ def wait(seconds=2):
|
|||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
def enAbleDontKeepA(d):
|
||||
d.press("home")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.android.launcher3:id/layout").child(index="1").child(index="2").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Search Apps…").set_text("Settings")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.android.launcher3:id/icon", text="Settings").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(description="Search settings").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Search…").set_text("keep activities")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Don’t keep activities").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Don’t keep activities").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
enAbleDontKeepA(d)
|
||||
|
||||
os.system(
|
||||
"adb root && adb shell am start -n org.mozilla.rocket.debug.ting/org.mozilla.focus.activity.MainActivity")
|
||||
# d.app_start("org.mozilla.rocket.debug.ting")
|
||||
|
@ -31,8 +71,6 @@ if __name__ == '__main__':
|
|||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
d.shell("settings put global always_finish_activities 1")
|
||||
|
||||
out = d(text="OK").click()
|
||||
if not out:
|
||||
print("Success: press OK")
|
||||
|
@ -59,8 +97,6 @@ if __name__ == '__main__':
|
|||
print("Success: press Firefox Lite Dev")
|
||||
wait()
|
||||
|
||||
d.shell("settings put global always_finish_activities 0")
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
|
|
|
@ -18,6 +18,9 @@ if __name__ == '__main__':
|
|||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
os.system("adb push music1.mp3 sdcard/Music")
|
||||
os.system("adb push music2.mp3 sdcard/Music")
|
||||
|
||||
d.app_start("com.kabouzeid.gramophone.debug")
|
||||
wait()
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
# bug reproduction script for bug #114 of Scarlet-Notes
|
||||
# This one requires two songs in the music folder
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
@ -18,24 +17,98 @@ if __name__ == '__main__':
|
|||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
d.app_start("com.kabouzeid.gramophone.debug")
|
||||
d.app_start("com.bijoysingh.quicknote")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "com.kabouzeid.gramophone.debug":
|
||||
if current_app['package'] == "com.bijoysingh.quicknote":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
out = d(text="GET STARTED").click()
|
||||
out = d(resourceId="com.bijoysingh.quicknote:id/lithoBottomToolbar").child(index="0").child(index="1").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="SHUFFLE ALL").click()
|
||||
out = d(text="Add Notebook").set_text("myBook")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("enter")
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="myBook").click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
|
||||
out = d(resourceId="com.bijoysingh.quicknote:id/lithoBottomToolbar", index="2").child(index="0").child(index="3").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Add Heading…").set_text("Note1")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.bijoysingh.quicknote:id/lithoBottomToolbar", index="2").child(index="0").child(index="3").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Add Heading…").set_text("Note2")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Note1").long_click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
wait()
|
||||
|
||||
out = d(text="Lock Note").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.bijoysingh.quicknote:id/lithoBottomToolbar", index="2").child(index="0").child(index="0").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Locked").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.bijoysingh.quicknote:id/lithoPreBottomToolbar", index="1").click(offset=(0.05, 0.5))
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
|
|
@ -0,0 +1,50 @@
|
|||
# bug reproduction script for bug #10302 of wordpress
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
||||
import uiautomator2 as u2
|
||||
|
||||
|
||||
def wait(seconds=2):
|
||||
for i in range(0, seconds):
|
||||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
|
||||
d.app_start("org.wordpress.android")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "org.wordpress.android":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/login_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login button")
|
||||
|
||||
wait()
|
||||
out = d(text="HELP").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
out = d.service("uiautomator").running()
|
||||
if not out:
|
||||
print("DISCONNECT UIAUTOMATOR2 SUCCESS")
|
||||
break
|
||||
time.sleep(2)
|
|
@ -0,0 +1,96 @@
|
|||
# bug reproduction script for bug #10363 of wordpress
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
||||
import uiautomator2 as u2
|
||||
|
||||
|
||||
def wait(seconds=2):
|
||||
for i in range(0, seconds):
|
||||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
|
||||
d.app_start("org.wordpress.android")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "org.wordpress.android":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/login_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login button")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.TextView", resourceId="org.wordpress.android:id/login_site_button_text").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login in via site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input").set_text(
|
||||
"testkkksite.wordpress.com")
|
||||
if out:
|
||||
print("SUCCESS: input site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Username").set_text(
|
||||
"testkkksite")
|
||||
if out:
|
||||
print("SUCCESS: input user name")
|
||||
|
||||
wait()
|
||||
d.press("back")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Password").set_text(
|
||||
"W11j141993")
|
||||
if out:
|
||||
print("SUCCESS: input password")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
out = d(text="CONTINUE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Blog Posts").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(description="Switch to list view").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
out = d.service("uiautomator").running()
|
||||
if not out:
|
||||
print("DISCONNECT UIAUTOMATOR2 SUCCESS")
|
||||
break
|
||||
time.sleep(2)
|
|
@ -0,0 +1,157 @@
|
|||
# bug reproduction script for bug #10547 of wordpress
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
||||
import uiautomator2 as u2
|
||||
|
||||
|
||||
def wait(seconds=2):
|
||||
for i in range(0, seconds):
|
||||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
def enAbleDontKeepA(d):
|
||||
d.press("home")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.android.launcher3:id/layout").child(index="1").child(index="2").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Search Apps…").set_text("Settings")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.android.launcher3:id/icon", text="Settings").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(description="Search settings").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Search…").set_text("keep activities")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Don’t keep activities").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Don’t keep activities").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
enAbleDontKeepA(d)
|
||||
|
||||
d.app_start("org.wordpress.android")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "org.wordpress.android":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/login_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login button")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.TextView", resourceId="org.wordpress.android:id/login_site_button_text").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login in via site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText").set_text("testkkksite.wordpress.com")
|
||||
if out:
|
||||
print("SUCCESS: input site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Username").set_text(
|
||||
"testkkksite")
|
||||
if out:
|
||||
print("SUCCESS: input user name")
|
||||
|
||||
wait()
|
||||
d.press("back")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Password").set_text(
|
||||
"W11j141993")
|
||||
if out:
|
||||
print("SUCCESS: input password")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait(5)
|
||||
|
||||
out = d(text="CONTINUE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/quick_action_buttons_container").child(index="2").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DRAFTS").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(10)
|
||||
|
||||
out = d(text="Edit").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(description="More options").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Preview").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(10)
|
||||
|
||||
out = d(description="Navigate up").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
out = d.service("uiautomator").running()
|
||||
if not out:
|
||||
print("DISCONNECT UIAUTOMATOR2 SUCCESS")
|
||||
break
|
||||
time.sleep(2)
|
|
@ -0,0 +1,111 @@
|
|||
# bug reproduction script for bug #10876 of wordpress
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
||||
import uiautomator2 as u2
|
||||
|
||||
|
||||
def wait(seconds=2):
|
||||
for i in range(0, seconds):
|
||||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
d.app_start("org.wordpress.android")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "org.wordpress.android":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/login_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login button")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.TextView", resourceId="org.wordpress.android:id/login_site_button_text").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login in via site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText").set_text("testkkksite.wordpress.com")
|
||||
if out:
|
||||
print("SUCCESS: input site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Username").set_text(
|
||||
"testkkksite")
|
||||
if out:
|
||||
print("SUCCESS: input user name")
|
||||
|
||||
wait()
|
||||
d.press("back")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Password").set_text(
|
||||
"W11j141993")
|
||||
if out:
|
||||
print("SUCCESS: input password")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait(5)
|
||||
|
||||
out = d(text="CONTINUE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/bottom_nav_new_post_button").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Share your story here…").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/format_bottom_bar_undo").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/format_bottom_bar_redo").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/format_bar_button_media_collapsed").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
out = d.service("uiautomator").running()
|
||||
if not out:
|
||||
print("DISCONNECT UIAUTOMATOR2 SUCCESS")
|
||||
break
|
||||
time.sleep(2)
|
|
@ -0,0 +1,106 @@
|
|||
# bug reproduction script for bug #11135 of wordpress
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
||||
import uiautomator2 as u2
|
||||
|
||||
|
||||
def wait(seconds=2):
|
||||
for i in range(0, seconds):
|
||||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
d.app_start("org.wordpress.android")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "org.wordpress.android":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/login_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login button")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.TextView", resourceId="org.wordpress.android:id/login_site_button_text").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login in via site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText").set_text("testkkksite.wordpress.com")
|
||||
if out:
|
||||
print("SUCCESS: input site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Username").set_text(
|
||||
"testkkksite")
|
||||
if out:
|
||||
print("SUCCESS: input user name")
|
||||
|
||||
wait()
|
||||
d.press("back")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Password").set_text(
|
||||
"W11j141993")
|
||||
if out:
|
||||
print("SUCCESS: input password")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait(5)
|
||||
|
||||
out = d(text="CONTINUE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/bottom_nav_reader_button").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(10)
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/card_view").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(5)
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/count_comments").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/button_expand").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
out = d.service("uiautomator").running()
|
||||
if not out:
|
||||
print("DISCONNECT UIAUTOMATOR2 SUCCESS")
|
||||
break
|
||||
time.sleep(2)
|
|
@ -0,0 +1,155 @@
|
|||
# bug reproduction script for bug #11992 of wordpress
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
||||
import uiautomator2 as u2
|
||||
|
||||
|
||||
def wait(seconds=2):
|
||||
for i in range(0, seconds):
|
||||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
def enAbleDontKeepA(d):
|
||||
d.press("home")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.android.launcher3:id/layout").child(index="1").child(index="2").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Search Apps…").set_text("Settings")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.android.launcher3:id/icon", text="Settings").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(description="Search settings").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Search…").set_text("keep activities")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Don’t keep activities").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Don’t keep activities").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
enAbleDontKeepA(d)
|
||||
|
||||
d.app_start("org.wordpress.android")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "org.wordpress.android":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/login_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login button")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.LinearLayout", resourceId="org.wordpress.android:id/login_site_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login in via site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText").set_text("testkkksite.wordpress.com")
|
||||
if out:
|
||||
print("SUCCESS: input site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Username").set_text(
|
||||
"testkkksite")
|
||||
if out:
|
||||
print("SUCCESS: input user name")
|
||||
|
||||
wait()
|
||||
d.press("back")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Password").set_text(
|
||||
"W11j141993")
|
||||
if out:
|
||||
print("SUCCESS: input password")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
wait(5)
|
||||
|
||||
out = d(text="CONTINUE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/bottom_nav_reader_button").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(10)
|
||||
|
||||
out = d(description="My Site. View your site and manage it, including stats.").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/scroll_view").swipe("up")
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Blog Posts").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(10)
|
||||
|
||||
out = d(description="Navigate up").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Blog Posts").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
out = d.service("uiautomator").running()
|
||||
if not out:
|
||||
print("DISCONNECT UIAUTOMATOR2 SUCCESS")
|
||||
break
|
||||
time.sleep(2)
|
|
@ -0,0 +1,204 @@
|
|||
# bug reproduction script for bug #6530 of wordpress
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
||||
import uiautomator2 as u2
|
||||
|
||||
|
||||
def wait(seconds=2):
|
||||
for i in range(0, seconds):
|
||||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
d.app_start("com.android.camera2")
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "com.android.camera2":
|
||||
break
|
||||
# d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
for x in range(15):
|
||||
out = d(resourceId="com.android.camera2:id/shutter_button").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(3)
|
||||
|
||||
|
||||
d.app_start("org.wordpress.android")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "org.wordpress.android":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/login_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login button")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/secondary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login in via site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText").set_text("testkkksite.wordpress.com")
|
||||
if out:
|
||||
print("SUCCESS: input site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait()
|
||||
out = d(className="TextInputLayout", text="Username").child(className="android.widget.EditText").set_text(
|
||||
"testkkksite")
|
||||
if out:
|
||||
print("SUCCESS: input user name")
|
||||
|
||||
wait()
|
||||
out = d(className="TextInputLayout", text="Password").child(className="android.widget.EditText").set_text(
|
||||
"W11j141993")
|
||||
if out:
|
||||
print("SUCCESS: input password")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
wait(10)
|
||||
|
||||
out = d(text="CONTINUE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="TRY IT").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(description="Navigate up").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Blog Posts").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/fab_button").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Share your story here…").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/format_bar_button_media").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/recycler").child(index="0").long_click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
for x in range(2, 9):
|
||||
out = d(resourceId="org.wordpress.android:id/recycler").child(index=str(x)).long_click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/recycler").swipe("up")
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/recycler").child(index="6").long_click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/recycler").child(index="7").long_click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/recycler").child(index="8").long_click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/recycler").swipe("up")
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/recycler").child(index="6").long_click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/recycler").child(index="7").long_click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/recycler").child(index="8").long_click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/mnu_confirm_selection").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(1)
|
||||
|
||||
out = d(text="TURN ON").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(1)
|
||||
|
||||
out = d(description="Navigate up").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(1)
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/btn_trash").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(1)
|
||||
|
||||
out = d(text="DELETE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(1)
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
out = d.service("uiautomator").running()
|
||||
if not out:
|
||||
print("DISCONNECT UIAUTOMATOR2 SUCCESS")
|
||||
break
|
||||
time.sleep(2)
|
|
@ -0,0 +1,85 @@
|
|||
# bug reproduction script for bug #7182 of wordpress
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
||||
import uiautomator2 as u2
|
||||
|
||||
|
||||
def wait(seconds=2):
|
||||
for i in range(0, seconds):
|
||||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
|
||||
d.app_start("org.wordpress.android")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "org.wordpress.android":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/login_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login button")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/secondary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login in via site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText").set_text("testkkksite.wordpress.com")
|
||||
if out:
|
||||
print("SUCCESS: input site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait()
|
||||
out = d(className="TextInputLayout", text="Username").child(className="android.widget.EditText").set_text(
|
||||
"testkkksite")
|
||||
if out:
|
||||
print("SUCCESS: input user name")
|
||||
|
||||
wait()
|
||||
d.press("back")
|
||||
wait()
|
||||
|
||||
out = d(className="TextInputLayout", text="Password").child(className="android.widget.EditText").set_text(
|
||||
"W11j141993")
|
||||
if out:
|
||||
print("SUCCESS: input password")
|
||||
|
||||
wait()
|
||||
d.set_orientation("l")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
wait(10)
|
||||
|
||||
d.set_orientation("n")
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
out = d.service("uiautomator").running()
|
||||
if not out:
|
||||
print("DISCONNECT UIAUTOMATOR2 SUCCESS")
|
||||
break
|
||||
time.sleep(2)
|
|
@ -0,0 +1,125 @@
|
|||
# bug reproduction script for bug #8659 of wordpress
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
||||
import uiautomator2 as u2
|
||||
|
||||
|
||||
def wait(seconds=2):
|
||||
for i in range(0, seconds):
|
||||
print("wait 1 second ..")
|
||||
time.sleep(1)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
||||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
|
||||
d.app_start("org.wordpress.android")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "org.wordpress.android":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/login_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login button")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.TextView", resourceId="org.wordpress.android:id/login_site_button_text").click()
|
||||
if not out:
|
||||
print("SUCCESS: press login in via site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText").set_text("testkkksite.wordpress.com")
|
||||
if out:
|
||||
print("SUCCESS: input site address")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Username").set_text(
|
||||
"testkkksite")
|
||||
if out:
|
||||
print("SUCCESS: input user name")
|
||||
|
||||
wait()
|
||||
d.press("back")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.EditText", resourceId="org.wordpress.android:id/input", text="Password").set_text(
|
||||
"W11j141993")
|
||||
if out:
|
||||
print("SUCCESS: input password")
|
||||
|
||||
wait()
|
||||
out = d(className="android.widget.Button", resourceId="org.wordpress.android:id/primary_button").click()
|
||||
if not out:
|
||||
print("SUCCESS: press next")
|
||||
wait(10)
|
||||
|
||||
out = d(text="CONTINUE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/nav_reader").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(5)
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/menu_reader_search").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Search WordPress").set_text("a")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.click(0.925, 0.9167)
|
||||
wait()
|
||||
|
||||
out = d(text="SITES").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
for x in range(4):
|
||||
out = d(resourceId="org.wordpress.android:id/recycler_view").swipe("up", steps=5)
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
|
||||
wait()
|
||||
|
||||
out = d(resourceId="org.wordpress.android:id/recycler_view").child(index="7").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(5)
|
||||
|
||||
out = d(description="Navigate up").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(5)
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
out = d.service("uiautomator").running()
|
||||
if not out:
|
||||
print("DISCONNECT UIAUTOMATOR2 SUCCESS")
|
||||
break
|
||||
time.sleep(2)
|
|
@ -1,4 +1,4 @@
|
|||
# bug reproduction script for bug #745 of Omni-Notes
|
||||
# bug reproduction script for bug #2198 of attendee
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
@ -17,64 +17,34 @@ if __name__ == '__main__':
|
|||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
d.app_start("it.feio.android.omninotes")
|
||||
d.app_start("com.eventyay.attendee")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "it.feio.android.omninotes":
|
||||
if current_app['package'] == "com.eventyay.attendee":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
out = d(resourceId="it.feio.android.omninotes:id/fab_expand_menu_button").click()
|
||||
out = d(text="Skip").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="it.feio.android.omninotes:id/fab_note").click()
|
||||
out = d(text="Skip for now").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Content").click()
|
||||
out = d(resourceId="com.eventyay.attendee:id/searchFragment").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="it.feio.android.omninotes:id/menu_attachment").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Camera").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.android.camera2:id/shutter_button").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.android.camera2:id/done_button").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(description="Navigate up").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="it.feio.android.omninotes:id/root").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="it.feio.android.omninotes:id/gridview_item_picture").click()
|
||||
out = d(text="Anything").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# bug reproduction script for bug #2198 of attendee
|
||||
# bug reproduction script for bug #67 of openlauncher
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
@ -17,34 +17,28 @@ if __name__ == '__main__':
|
|||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
d.app_start("com.eventyay.attendee")
|
||||
d.app_start("com.benny.openlauncher")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "com.eventyay.attendee":
|
||||
if current_app['package'] == "com.benny.openlauncher":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
out = d(text="Skip").click()
|
||||
out = d(text="SKIP").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Skip for now").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
d.swipe(0.0, 0.5, 0.5, 0.5)
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.eventyay.attendee:id/searchFragment").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Anything").click()
|
||||
out = d(resourceId="com.benny.openlauncher:id/minBar").child(index="6").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# bug reproduction script for bug #67 of openlauncher
|
||||
# bug reproduction script for bug #637 of osmeditor
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
@ -17,31 +17,118 @@ if __name__ == '__main__':
|
|||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
d.app_start("com.benny.openlauncher")
|
||||
d.app_start("de.blau.android")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "com.benny.openlauncher":
|
||||
if current_app['package'] == "de.blau.android":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
out = d(text="SKIP").click()
|
||||
out = d(text="OKAY").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.swipe(0.0, 0.5, 0.5, 0.5)
|
||||
out = d(resourceId="de.blau.android:id/location_current").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="LOAD").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait(10)
|
||||
|
||||
out = d(resourceId="de.blau.android:id/menu_config").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
for x in range(2):
|
||||
out = d(resourceId="de.blau.android:id/list").swipe("up", steps=10)
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait(1)
|
||||
|
||||
out = d(text="Validator preferences").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
for x in range(6):
|
||||
out = d(resourceId="de.blau.android:id/listViewResurvey").child(index="0").child(index="0").child(text="amenity").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DELETE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="name").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DELETE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="opening_hours").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DELETE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="wheelchair").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DELETE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="de.blau.android:id/listViewResurvey").child(index="0").child(index="0").child(
|
||||
text="shop").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="de.blau.android:id/resurvey_value").set_text("*")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="de.blau.android:id/display").set_text("0")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="SAVE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DONE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.benny.openlauncher:id/minBar").child(index="6").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# bug reproduction script for bug #637 of osmeditor
|
||||
# bug reproduction script for bug #729 of osmeditor
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
@ -44,92 +44,46 @@ if __name__ == '__main__':
|
|||
print("SUCCESS")
|
||||
wait(10)
|
||||
|
||||
out = d(resourceId="de.blau.android:id/menu_config").click()
|
||||
out = d(resourceId="de.blau.android:id/map_view").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
for x in range(2):
|
||||
out = d(resourceId="de.blau.android:id/list").swipe("up", steps=10)
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait(1)
|
||||
|
||||
out = d(text="Validator preferences").click()
|
||||
out = d(resourceId="de.blau.android:id/floatingLock").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
for x in range(6):
|
||||
out = d(resourceId="de.blau.android:id/listViewResurvey").child(index="0").child(index="0").child(text="amenity").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DELETE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="name").click()
|
||||
out = d(resourceId="de.blau.android:id/map_view").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DELETE").click()
|
||||
out = d(resourceId="android:id/select_dialog_listview").child(textContains="Footway").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="opening_hours").click()
|
||||
out = d(resourceId="de.blau.android:id/cab_stub").child(index="0").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DELETE").click()
|
||||
out = d(text="Presets").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="wheelchair").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DELETE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="de.blau.android:id/listViewResurvey").child(index="0").child(index="0").child(
|
||||
text="shop").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="de.blau.android:id/resurvey_value").set_text("*")
|
||||
out = d(text="Preset search string").set_text("search")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="de.blau.android:id/display").set_text("0")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="SAVE").click()
|
||||
out = d(className="android.widget.EditText", text="search").click(offset=(0.95, 0.5))
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="DONE").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
print("SUCCESS")
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
time.sleep(2)
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
# bug reproduction script for bug #114 of Scarlet-Notes
|
||||
# This one requires two songs in the music folder
|
||||
# bug reproduction script for bug #239 of sunflower
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
|
@ -18,101 +17,33 @@ if __name__ == '__main__':
|
|||
avd_serial = sys.argv[1]
|
||||
d = u2.connect(avd_serial)
|
||||
|
||||
d.app_start("com.bijoysingh.quicknote")
|
||||
d.app_start("com.google.samples.apps.sunflower")
|
||||
wait()
|
||||
|
||||
current_app = d.app_current()
|
||||
print(current_app)
|
||||
while True:
|
||||
if current_app['package'] == "com.bijoysingh.quicknote":
|
||||
if current_app['package'] == "com.google.samples.apps.sunflower":
|
||||
break
|
||||
#d.app_start("org.odk.collect.android")
|
||||
time.sleep(2)
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.bijoysingh.quicknote:id/lithoBottomToolbar").child(index="0").child(index="1").click()
|
||||
out = d(description="Navigate up").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Add Notebook").set_text("myBook")
|
||||
if out:
|
||||
out = d(text="Plant list").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("enter")
|
||||
x1, y1 = d(text="Beet").center()
|
||||
x2, y2 = d(text="Avocado").center()
|
||||
|
||||
d(className="androidx.recyclerview.widget.RecyclerView").gesture((x1, y1), (x2, y2), (x1, y1), (x2, y2), steps=50)
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="myBook").click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
|
||||
out = d(resourceId="com.bijoysingh.quicknote:id/lithoBottomToolbar", index="2").child(index="0").child(index="3").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Add Heading…").set_text("Note1")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.bijoysingh.quicknote:id/lithoBottomToolbar", index="2").child(index="0").child(index="3").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Add Heading…").set_text("Note2")
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Note1").long_click()
|
||||
if out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
d.press("back")
|
||||
wait()
|
||||
|
||||
out = d(text="Lock Note").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.bijoysingh.quicknote:id/lithoBottomToolbar", index="2").child(index="0").child(index="0").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(text="Locked").click()
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
out = d(resourceId="com.bijoysingh.quicknote:id/lithoPreBottomToolbar", index="1").click(offset=(0.05, 0.5))
|
||||
if not out:
|
||||
print("SUCCESS")
|
||||
wait()
|
||||
|
||||
while True:
|
||||
d.service("uiautomator").stop()
|
||||
|
|
Loading…
Reference in New Issue