完善切入iframe逻辑

This commit is contained in:
g1879 2021-03-24 08:47:50 +08:00
parent 6482dfec51
commit c9f73760ff

View File

@ -450,7 +450,7 @@ class DriverPage(object):
self.driver.switch_to.parent_frame()
# 传入id或name
elif ':' not in loc_or_ele and '=' not in loc_or_ele:
elif ':' not in loc_or_ele and '=' not in loc_or_ele and not loc_or_ele.startswith(('#', '.')):
self.driver.switch_to.frame(loc_or_ele)
# 传入控制字符串