本文整理汇总了Python中myLib.miro_app.MiroApp.delete_site方法的典型用法代码示例。如果您正苦于以下问题:Python MiroApp.delete_site方法的具体用法?Python MiroApp.delete_site怎么用?Python MiroApp.delete_site使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类myLib.miro_app.MiroApp
的用法示例。
在下文中一共展示了MiroApp.delete_site方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_182
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_site [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)
示例2: test_29
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_site [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")
示例3: test_194
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_site [as 别名]
def test_194(self):
"""http://litmus.pculture.org/show_test.cgi?id=194 rename source.
1. Add blip.tv as a source
2. rename
3. restart and verify name persists
4. Cleanup
"""
site_url = "http://blip.tv"
site = "blip"
reg = MiroRegions()
miro = MiroApp()
miro.add_source(reg, site_url,site)
miro.click_source(reg, site)
reg.t.click("Sidebar")
reg.t.click("Rename")
time.sleep(3)
type("BLIP TV ROCKS \n")
self.assertTrue(reg.s.exists("BLIP TV ROCKS"))
miro.quit_miro()
reg = MiroRegions()
miro = MiroApp()
self.assertTrue(reg.s.exists("BLIP"))
miro.delete_site(reg, "BLIP")
示例4: stest_39
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_site [as 别名]
def stest_39(self):
"""http://litmus.pculture.org/show_test.cgi?id=39 site navigation.
#skipping for now will fix later.
1. Add blip.tv as a source
2. navigate through site
3. verify nav buttons and states
4. Cleanup
"""
site_url = "http://blip.tv"
site = "blip"
reg = MiroRegions()
miro = MiroApp()
miro.add_source(reg, site_url,site)
miro.click_source(reg, site)
time.sleep(10)
find("navstop_disabled.png")
find("navforward_disabled.png")
find("navhome.png")
find("navreload.png")
reg.m.click(myLib.testvars.blip_browse)
reg.m.click(myLib.testvars.blip_recent)
self.assertTrue(reg.mtb.exists("navback.png"))
self.assertTrue(reg.mtb.exists("navforward_disabled.png"))
self.assertTrue(reg.mtb.exists("navhome.png"))
self.assertTrue(reg.mtb.exists("navreload.png"))
reg.mtb.click("navback.png")
self.assertTrue(reg.mtb.exists("navforward.png"))
self.assertTrue(reg.mtb.exists("navback_disabled.png"))
self.assertTrue(reg.mtb.exists("navhome.png"))
self.assertTrue(reg.mtb.exists("navreload.png"))
reg.mtb.click("navforward")
self.assertTrue(reg.mtb.exists("navback.png"))
self.assertTrue(reg.mtb.exists("navforward_disabled.png"))
self.assertTrue(reg.mtb.exists("navhome.png"))
self.assertTrue(reg.mtb.exists("navreload.png"))
reg.mtb.click("navreload.png")
reg.mtb.click("navstop.png")
self.assertTrue(reg.mtb.exists("navback.png"))
self.assertTrue(reg.mtb.exists("navforward.png"))
self.assertTrue(reg.mtb.exists("navhome.png"))
self.assertTrue(reg.mtb.exists("navreload.png"))
reg.mtb.click("navhome.png")
#FIX MEwait for the updating icon to appear then disappear
self.assertTrue(reg.mtb.exists("navback.png"))
self.assertTrue(reg.mtb.exists("navforward_disabled.png"))
self.assertTrue(reg.mtb.exists("navhome.png"))
self.assertTrue(reg.mtb.exists("navreload.png"))
miro.delete_site(reg, site)
示例5: test_195
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_site [as 别名]
def test_195(self):
"""http://litmus.pculture.org/show_test.cgi?id=196 delete site.
1. Add header test as a source
2. delete it
"""
site_url = "http://qa.pculture.org/feeds_test/header-test.php"
site = "Header Test"
reg = MiroRegions()
miro = MiroApp()
miro.add_source(reg, site_url,site)
miro.delete_site(reg, site)
示例6: skip_192
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_site [as 别名]
def skip_192(self):
"""http://litmus.pculture.org/show_test.cgi?id=192 file detection dl.
1. Add clearbits.net page as a source
2. click to dl the torrent file
3. Verify file starts to download
4. Cleanup
"""
site_url = "http://pculture.org/feeds_test/http-direct-downloads.html"
site = "HTTP Direct"
## FIX ME - Need new files, can't download from the videolan ftp site anymore
HTTPDOWNLOADS = {".mpFour download":"big",
".mpThree download":"gd",
".mFoura download":"luckynight",
# ".mpeg download":"mighty",
# ".ogv download":"popeye",
# ".mov download":"Matrix",
# ".wmv download":"WindowsMedia",
# ".avi download":"Coyote",
# ".mpg download":"dothack2",
# ".mkv download 2":"mulitple",
# ".ogg download":"gd",
# ".wma download":"Bangles",
# ".flac download":"luckynight",
# ".mka download":"Widow",
}
setAutoWaitTimeout(20)
reg = MiroRegions()
miro = MiroApp()
miro.add_source(reg, site_url,site)
miro.click_source(reg, site)
for filetype, title in HTTPDOWNLOADS.iteritems():
try:
if reg.m.exists(filetype):
click(reg.m.getLastMatch())
else:
type(Key.PAGE_DOWN)
reg.m.find(filetype)
click(reg.m.getLastMatch())
if miro.confirm_download_started(reg, title) == "failed":
self.verificationErrors.append("download failed for imagetype" +str(filetype))
else:
reg.mtb.click("download-cancel.png")
miro.click_source(reg, site)
except:
self.verificationErrors.append("download failed for imagetype" +str(filetype))
finally:
type(Key.ESC) #Close any lingering dialogs
miro.cancel_all_downloads(reg)
miro.delete_site(reg, site)
示例7: test_194
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_site [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)
示例8: test_191
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_site [as 别名]
def test_191(self):
"""http://litmus.pculture.org/show_test.cgi?id=191 Add rss feed to sidebar.
1. Add ClearBits.net as a source
2. Open Netlabel Music page and add RSS feed
3. Verify feed added to the sidebar
4. Cleanup
"""
site_url = "http://clearbits.net"
site = "ClearBits"
feed = "ClearBits"
reg = MiroRegions()
miro = MiroApp()
miro.add_source(reg, site_url,site)
miro.click_source(reg, site)
reg.m.click("Netlabel Music")
reg.m.click(myLib.testvars.clearbits_rss)
miro.click_podcast(reg, site)
miro.log_result("29","test_191 verify 1-click add site from source.")
time.sleep(3)
miro.delete_feed(reg, feed)
miro.delete_site(reg, site)
示例9: test_143
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_site [as 别名]
def test_143(self):
"""http://litmus.pculture.org/show_test.cgi?id=143 multiple delete and cancel.
1. Add clearbits and archive.org
2. select bogh and delete, the cancel
3. verify sites not deleted.
4. Cleanup
"""
site_url = "http://clearbits.net"
site_url2 = "http://archive.org"
site = "ClearBits"
site2 = "Internet"
setAutoWaitTimeout(60)
reg = MiroRegions()
miro = MiroApp()
miro.add_source(reg, site_url,site)
miro.add_source(reg, site_url2,site2)
p = miro.get_sources_region(reg)
p.click(site)
keyDown(Key.SHIFT)
p.click(site2)
keyUp(Key.SHIFT)
if reg.m.exists("Delete All",5) or \
reg.m.exists(Pattern("button_mv_delete_all.png"),5):
click(reg.m.getLastMatch())
else:
self.fail("Delete All button for multi-select not found")
miro.remove_confirm(reg, "cancel")
time.sleep(3)
p = miro.get_sources_region(reg)
time.sleep(3)
self.assertTrue(p.exists(site))
self.assertTrue(p.exists(site2))
#Cleanup
miro.delete_site(reg, site)
miro.delete_site(reg, site2)
示例10: test_193
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_site [as 别名]
def test_193(self):
"""http://litmus.pculture.org/show_test.cgi?id=193 torrent direct dl.
1. Add clearbits.net page as a source
2. click to dl the torrent file
3. Verify file starts to download
4. Cleanup
"""
site_url = "http://www.clearbits.net/torrents/662-here-be-dragons-ipod"
site = "ClearBits"
title = "Dragons"
reg = MiroRegions()
miro = MiroApp()
miro.cancel_all_downloads(reg)
miro.add_source(reg, site_url,site)
miro.click_source(reg, site)
reg.m.click("Torrent file")
miro.confirm_download_started(reg, title)
miro.cancel_all_downloads(reg)
miro.delete_site(reg, site)