本文整理汇总了Python中myLib.miro_app.MiroApp.http_auth方法的典型用法代码示例。如果您正苦于以下问题:Python MiroApp.http_auth方法的具体用法?Python MiroApp.http_auth怎么用?Python MiroApp.http_auth使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类myLib.miro_app.MiroApp
的用法示例。
在下文中一共展示了MiroApp.http_auth方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_76
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import http_auth [as 别名]
def test_76(self):
"""http://litmus.pculture.org/show_test.cgi?id=76 item http auth
1. add the pass protected feed
2. click to download the item
3. enter a few invalid combos, then valid
4. Verify download starts
"""
reg = MiroRegions()
miro = MiroApp()
time.sleep(5)
url = "http://participatoryculture.org/feeds_test/feed1.rss"
feed = "Yah"
term = "fourth test"
title = "Video 4"
BAD_PASSW = {"auser":"apassw",
"12341234":"12341234",
" ": " ",
" ":"password",
"username": " "
}
miro.remove_http_auth_file(reg)
#add feed and download 4th item
miro.add_feed(reg, url,feed)
miro.tab_search(reg, term)
reg.m.click("button_download.png")
for username, passw in BAD_PASSW.iteritems():
miro.http_auth(reg, username,passw)
miro.http_auth(reg, username="tester", passw="pcfdudes")
time.sleep(5)
miro.confirm_download_started(reg, title)
#cleanup
miro.delete_feed(reg, feed)
if miro.remove_http_auth_file(reg) == False:
self.fail("auth file not saved on filesystem")