本文整理汇总了Python中myLib.miro_app.MiroApp.delete_items方法的典型用法代码示例。如果您正苦于以下问题:Python MiroApp.delete_items方法的具体用法?Python MiroApp.delete_items怎么用?Python MiroApp.delete_items使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类myLib.miro_app.MiroApp
的用法示例。
在下文中一共展示了MiroApp.delete_items方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: test_419
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_items [as 别名]
def test_419(self):
"""http://litmus.pculture.org/show_test.cgi?id=419 external torrent dl.
1. clearbits torrent dl
2. open with File Download menu
3. Verify download started and metadata
4. Cleanup
"""
reg = MiroRegions()
miro = MiroApp()
item_url = "http://youtorrent.com/download/7379834/young-broke-and-fameless-the-mixtape.torrent"
item_title = "Fameless"
reg.tl.click("File")
reg.tl.click("Download from")
time.sleep(5)
type(item_url+"\n")
print ("confirm download started")
status = miro.confirm_download_started(reg, item_title)
print status
if status == "downloaded":
miro.delete_items(reg, item_title,"Misc")
elif status == "in_progress":
miro.delete_items(reg, item_title,"Downloading")
else:
self.fail("Can not confirm download started")
示例2: test_364
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_items [as 别名]
def test_364(self):
"""http://litmus.pculture.org/show_test.cgi?id=364 edit item misc to video
1. Download item that lands in Misc
2. Edit type to video
3. start playback and verify play external dialog
4. cleanup
"""
reg = MiroRegions()
miro = MiroApp()
time.sleep(5)
url = "http://vimeo.com/moogaloop_local.swf?clip_id=7335370&server=vimeo.com"
title = "local"
#Set Global Preferences
miro.open_prefs(reg)
prefs = PreferencesPanel()
general_tab = prefs.open_tab("General")
general_tab.show_videos_in_videos("on")
general_tab.close_prefs()
miro.cancel_all_downloads(reg)
reg.tl.click("File")
reg.tl.click("Download from")
time.sleep(4)
type(url)
time.sleep(10)
type("\n")
if reg.s.exists("Downloading"):
print "item dl started"
reg.s.waitVanish("Downloading",120)
time.sleep(5)
miro.wait_for_item_in_tab(reg, tab="Misc",item=title)
x = reg.m.find(title)
click(x)
reg.s.find("Music")
tmpr = Region(reg.s.getLastMatch().above())
tmpr.setW(tmpr.getW()+80)
tmpr.setX(tmpr.getX()-20)
y = tmpr.find("Videos")
dragDrop(x,y)
#locate item in video tab and verify playback
click(y)
if reg.m.exists(title):
doubleClick(reg.m.getLastMatch())
miro.verify_video_playback(reg)
miro.delete_items(reg, title,"Videos")
else:
miro.delete_items(reg, title,"Videos")
self.fail("item not found in videos tab")
示例3: test_339
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_items [as 别名]
def test_339(self):
"""http://litmus.pculture.org/show_test.cgi?id=339 delete feed with dl items.
Litmus Test Title:: 339 - channels delete a feed with downloaded items
Description:
1. Add the 2-stupid-videos feed, and download both items in the feed.
2. Remove Feed and Keep the videos.
3. Verify videos are displayed in the non-feed section of the Library
4. Cleanup
"""
#set the search regions
reg = MiroRegions()
miro = MiroApp()
url = "http://pculture.org/feeds_test/2stupidvideos.xml"
feed = "TWO STUPID"
#1. Add the feed and start dl
miro.add_feed(reg, url,feed)
time.sleep(3)
miro.toggle_normal(reg)
# miro.count_images(reg, "item-context-button.png",region="mainright",num_expected=2)
miro.set_podcast_autodownload(reg, setting="All")
miro.wait_for_item_in_tab(reg, "videos","Flip")
miro.wait_for_item_in_tab(reg, "videos","Dinosaur")
miro.click_podcast(reg, feed)
type(Key.DELETE)
miro.remove_confirm(reg, action="keep")
miro.click_sidebar_tab(reg, "videos")
miro.tab_search(reg, "Flip",confirm_present=True)
miro.tab_search(reg, "Dinosaur",confirm_present=True)
#4. cleanup
miro.delete_items(reg, "Flip","videos")
miro.delete_items(reg, "Dinosaur","videos")
示例4: test_719
# 需要导入模块: from myLib.miro_app import MiroApp [as 别名]
# 或者: from myLib.miro_app.MiroApp import delete_items [as 别名]
def test_719(self):
"""http://litmus.pculture.org/show_test.cgi?id=719 external torrent dl from browser
1. clearbits torrent dl
2. open with browser
3. Verify download started and metadata
4. Cleanup
"""
reg = MiroRegions()
miro = MiroApp()
url = "http://www.clearbits.net/get/993-wurlitztraction---lucidity-cue.torrent"
item_title = "Enough"
miro.browser_to_miro(reg, url)
print ("confirm download started")
status = miro.confirm_download_started(reg, item_title)
print status
if status == "downloaded":
miro.delete_items(reg, item_title,"Misc")
elif status == "in_progress":
miro.delete_items(reg, item_title,"Downloading")
else:
self.fail("Can not confirm download started")