本文整理汇总了Python中myLib.miro_app.MiroApp.add_source_from_tab方法的典型用法代码示例。如果您正苦于以下问题:Python MiroApp.add_source_from_tab方法的具体用法?Python MiroApp.add_source_from_tab怎么用?Python MiroApp.add_source_from_tab使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类myLib.miro_app.MiroApp
的用法示例。
在下文中一共展示了MiroApp.add_source_from_tab方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_29
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import add_source_from_tab [as 别名]
def test_29(self):
"""http://litmus.pculture.org/show_test.cgi?id=29 add site from miro site.
1. Open Awesome website
2. click one-click subscribe link for revver
3. Verify site added
4. Cleanup
"""
reg = MiroRegions()
miro = MiroApp()
site_url = "http://pculture.org/feeds_test/subscription-test-guide.html"
site = "Awesome"
site2 = "Revver"
miro.add_source_from_tab(reg, site_url)
miro.click_last_source(reg)
reg.t.find("Subscribe")
reg.t.click("Subscribe")
time.sleep(4)
p = miro.get_sources_region(reg)
if p.exists("http://rev",3) or \
p.exists("revver",3):
print "revver site added"
else:
self.fail("revver site not added to sidebar")
miro.delete_site(reg, site)
miro.delete_site(reg, "revver")
示例2: test_182
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import add_source_from_tab [as 别名]
def test_182(self):
"""http://litmus.pculture.org/show_test.cgi?id=182 dl from youtube site.
1. Open youtube url as site
2. download button
3. verify download started
4. Cleanup
"""
site_url = "http://www.youtube.com/watch?v=fgg2tpUVbXQ&feature=channel"
site = "Hubble"
reg = MiroRegions()
miro = MiroApp()
try:
miro.add_source_from_tab(reg, site_url)
miro.click_last_source(reg)
if reg.mtb.exists(Pattern("download_this_video.png")) or \
reg.mtb.exists("Download this"):
click(reg.mtb.getLastMatch())
time.sleep(3)
miro.confirm_download_started(reg, "Deep")
reg.mtb.click("download-cancel.png")
finally:
miro.delete_site(reg, site)
示例3: test_321
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import add_source_from_tab [as 别名]
def test_321(self):
"""http://litmus.pculture.org/show_test.cgi?id=321 delete slow to load site.
1. Add slow feed as a source
2. delete it before is loads
"""
site_url = "http://pculture.org/feeds_test/slowsite.php"
site = "pculture"
alt_site = "Miro Guide"
setAutoWaitTimeout(60)
reg = MiroRegions()
miro = MiroApp()
miro.add_source_from_tab(reg, site_url)
miro.click_last_source(reg)
type(Key.DELETE)
type(Key.ENTER)
miro.handle_crash_dialog(db=False,test=False)
示例4: test_194
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import add_source_from_tab [as 别名]
def test_194(self):
"""http://litmus.pculture.org/show_test.cgi?id=194 site with non-utf-8 chars.
1. Add http://qa.pculture.org/feeds_test/test-guide-unicode.html
2. Verify added
3. Restart and verify still there
4. Cleanup
"""
site_url = "http://qa.pculture.org/feeds_test/test-guide-unicode.html"
site = "Awesome"
reg = MiroRegions()
miro = MiroApp()
miro.add_source_from_tab(reg, site_url)
miro.click_last_source(reg)
reg.m.find("unicode")
miro.quit_miro()
miro.restart_miro()
miro.click_last_source(reg)
self.assertTrue(reg.m.exists("unicode"))
miro.delete_site(reg, site)
示例5: test_194
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import add_source_from_tab [as 别名]
def test_194(self):
"""http://litmus.pculture.org/show_test.cgi?id=194 site with non-utf-8 chars.
1. Add http://diziizle.net/
2. Verify added
3. Restart and verify still there
4. Cleanup
"""
site_url = "http://diziizle.net/"
site = "diziizle"
setAutoWaitTimeout(60)
reg = MiroRegions()
miro = MiroApp()
miro.add_source_from_tab(reg, site_url)
miro.click_last_source(reg)
reg.m.find(myLib.testvars.dizizle_logo)
miro.quit_miro()
miro.restart_miro()
miro.click_last_source(reg)
self.assertTrue(reg.m.exists(myLib.testvars.dizizle_logo))
miro.delete_site(reg, site)