Exemple #1
0
    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
        """

    	setAutoWaitTimeout(testvars.timeout)   
        #set the search regions
    	reg = mirolib.AppRegions()

    	url = "http://pculture.org/feeds_test/2stupidvideos.xml"
    	feed = "TwoStupid"

    	#1. Add the feed and start dl
    	mirolib.add_feed(self,reg,url,feed)
    	time.sleep(3)
    	mirolib.toggle_normal(reg)
#    	mirolib.count_images(self,reg, "item-context-button.png",region="mainright",num_expected=2)
    	mirolib.set_podcast_autodownload(self,reg,setting="All")
    	mirolib.wait_for_item_in_tab(self,reg,"videos","Flip")
    	mirolib.wait_for_item_in_tab(self,reg,"videos","Dinosaur")
    	mirolib.click_podcast(self,reg,feed)
    	type(Key.DELETE)
    	mirolib.remove_confirm(self,reg,action="keep")
    	mirolib.click_sidebar_tab(self,reg,"videos")
    	mirolib.tab_search(self,reg,"Flip",confirm_present=True)
    	mirolib.tab_search(self,reg,"Dinosaur",confirm_present=True)
    	#4. cleanup
    	mirolib.delete_items(self,reg,"Flip","videos")
    	mirolib.delete_items(self,reg,"Dinosaur","videos")
Exemple #2
0
    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 = mirolib.AppRegions()
        
        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 = mirolib.confirm_download_started(self,reg,item_title)
        print status
        if status == "downloaded":
            mirolib.delete_items(self,reg,item_title,"Misc")
        elif status == "in_progress":
            mirolib.delete_items(self,reg,item_title,"Downloading")
        else:
            self.fail("Can not confirm download started")
Exemple #3
0
    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 = mirolib.AppRegions()
        time.sleep(5)
        url = "http://vimeo.com/moogaloop_local.swf?clip_id=7335370&server=vimeo.com"
        title = "local"
        #Set Global Preferences
        prefs.set_item_display(self,reg,option="video",setting="on")
        time.sleep(2)
        mirolib.cancel_all_downloads(self,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)
        mirolib.wait_for_item_in_tab(self,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())
            mirolib.verify_video_playback(self,reg)
            mirolib.delete_items(self,reg,title,"Videos")
        else:
            mirolib.delete_items(self,reg,title,"Videos")
            self.fail("item not found in videos tab")
Exemple #4
0
    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 = mirolib.AppRegions()
        
        url = "http://www.clearbits.net/get/993-wurlitztraction---lucidity-cue.torrent"
        item_title = "Enough"
        mirolib.browser_to_miro(self,reg,url)
        print ("confirm download started")
        status = mirolib.confirm_download_started(self,reg,item_title)
        print status
        if status == "downloaded":
            mirolib.delete_items(self,reg,item_title,"Misc")
        elif status == "in_progress":
            mirolib.delete_items(self,reg,item_title,"Downloading")
        else:
            self.fail("Can not confirm download started")
Exemple #5
0
     
     # 3. Verify playback
     mirolib.click_sidebar_tab(self,reg,"music")
     aplaybackList = ("MP3",)
     for x in aplaybackList:
         mirolib.tab_search(self,reg,"Converted to "+str(x),False)
         if reg.m.exists(Pattern("item_play_unplayed.png")):
             doubleClick(reg.m.getLastMatch())
             mirolib.verify_audio_playback(self,reg,"Converted")
         else:
             self.fail("converted item not found")
 except FindFailed, debugging:
     self.verificationErrors.append(debugging)
 finally:
     while reg.m.exists(item_title,5):
         mirolib.delete_items(self,reg,item_title,"music")
                     
 
 # 4. Convert items to video formats
 try:
     vconvertList = ("Droid","Galaxy","G2","iPad","iPhone","MP4", "Theora","Playstation")
     mirolib.click_sidebar_tab(self,reg,"Videos")
     reg.m.click(item_title)
     
     for x in vconvertList:
         mirolib.convert_file(self,reg,x)
         time.sleep(15)
     mirolib.click_sidebar_tab(self,reg,"Converting")
     mirolib.wait_conversions_complete(self,reg,item_title,str(x))
     # 5. Verify playback
     mirolib.click_sidebar_tab(self,reg,"Videos")
Exemple #6
0
 def _delete_item(self):
     title = "detective"
     mirolib.wait_for_item_in_tab(self,reg,"Misc","detective")
     mirolib.delete_items(self,reg,title,"Misc")
     mirolib.log_result("92","delete item shortcut verified")
     time.sleep(5)