本文整理汇总了Python中PF_common_FF.locate_tracking_section方法的典型用法代码示例。如果您正苦于以下问题:Python PF_common_FF.locate_tracking_section方法的具体用法?Python PF_common_FF.locate_tracking_section怎么用?Python PF_common_FF.locate_tracking_section使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PF_common_FF
的用法示例。
在下文中一共展示了PF_common_FF.locate_tracking_section方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: PF_check_required_init
# 需要导入模块: import PF_common_FF [as 别名]
# 或者: from PF_common_FF import locate_tracking_section [as 别名]
def PF_check_required_init():
PF_common.locate_tracking_section(log_file )
rs=1
PD02_Orange=("PD02_Orange.png")
PD03_Orange=("PD03_Orange.png")
t1=PF_common.verify_continue_with_similarity(log_file,PD02_Orange,0.90)
t2=PF_common.verify_continue_with_similarity(log_file,PD03_Orange,0.90)
if t1==0 or t2==0:
PF_common.write_log_with_screenshot(log_file,"Personal Data & Tracking section is not orange")
rs=2
else:
PF_common.write_log_with_screenshot(log_file,"Personal Data & Tracking section IS orange!")
#PF_common.GoogleLogin(log_file)
#if PF_common.verify_continue_with_similarity(log_file,"GoogleSection.png", 0.90)==0:
# PF_common.write_log_with_screenshot(log_file,"Google section status is NOT set to orange!")
#rs=3
# if exists(Pattern(GL01_green).similar(0.90)):set_GL01_gray(log_file)
# if exists(Pattern(GL02_green).similar(0.90)):set_GL02_gray(log_file) This item is blocked by AP-882
# if exists(Pattern(GL03_green).similar(0.90)):set_GL03_gray(log_file)
# else:
# PF_common.write_log_with_screenshot(log_file,"Google section IS SET to orange!")
################################
# PF_common.TwitterLogIn(log_file)
# if PF_common.verify_continue_with_similarity(log_file,"TW_section.png",0.90)==0:
# PF_common.write_log_with_screenshot(log_file,"Twitter section in IS NOT orange")
# rs=4
# if exists(Pattern(TW01_green).similar(0.90)):set_TW01_grey(log_file)
# if exists(Pattern(TW02_green).similar(0.90)):set_TW02_grey(log_file)
# if exists(Pattern(TW03_green).similar(0.90)):set_TW03_grey(log_file)
# else:
# PF_common.write_log_with_screenshot(log_file,"Twitter section IS orange!")
#################################
PF_common.FacebookLogin(log_file)
if PF_common.verify_continue_with_similarity(log_file,"FisrstTwoItems_FB.png",0.90)==0:
PF_common.write_log_with_screenshot(log_file,"FB section1 is NOT orange")
rs=5
if exists(Pattern(FB01_green).similar(0.90)):set_FB01_grey(log_file)
if exists(Pattern(FB02_green).similar(0.90)):set_FB02_grey(log_file)
else:
PF_common.write_log_with_screenshot(log_file,"First two items in FB section are orange!")
type(Key.DOWN+Key.DOWN+Key.DOWN)
if PF_common.verify_continue_with_similarity(log_file,"1400763451939.png",0.90)==0:
PF_common.write_log_with_screenshot(log_file,"FB section2 is NOT orange")
rs=5
if exists(Pattern(FB04_green).similar(0.90)):set_FB04_grey(log_file)
if exists(Pattern(FB06_green).similar(0.90)):set_FB06_grey(log_file)
if exists(Pattern(FB07_green).similar(0.90)):set_FB07_grey(log_file)
else:
PF_common.write_log_with_screenshot(log_file,"Items from 4 till 9 are orange!")
PF_common.LinkedInLogIn(log_file)
if PF_common.verify_continue_with_similarity(log_file,"LK_section.png",0.90)==0:
PF_common.write_log_with_screenshot(log_file,"Linked in IS NOT orange")
rs=6
if exists(Pattern(LK01_green).similar(0.90)):set_LK01_grey(log_file)
if exists(Pattern(LK03_green).similar(0.90)):set_LK03_grey(log_file)
if exists(Pattern(LK05_green).similar(0.90)):set_LK05_grey(log_file)
else:
PF_common.write_log_with_screenshot(log_file,"LinkedIn section IS orange!")
PF_common.write_log_with_screenshot(log_file, "end of Init")
return rs