Automation of APP App test mix (before three operations on native APP)

Mixed developed App, there is often embedded H5 page: positioning method with different native APP, it requires a context switch

# Get all contexts
contexts = dr.contexts
Print (contexts)
# Print context (should be a problem webview)
cur_context = dr.current_context
Print (cur_context)
# switch to webview interface
dr.switch_to.context ( 'WEBVIEW_com.wondershare.drfone ')

Guess you like

Origin www.cnblogs.com/saran/p/11728095.html