Пример #1
0
    def test_23(self):
        """http://litmus.pculture.org/show_test.cgi?id=23 remember search.

        1. Add 2-stupid-videos feed
        2. Perform a search
        3. Type in search box the delete key 
        4. Cleanup

        """
        reg = MiroRegions() 
        miro = MiroApp()
        url = "http://pculture.org/feeds_test/2stupidvideos.xml"
        feed = "TWO STUPID"
        term = "House"
        title = "Dinosaur"
        
        #1. add feed
        miro.add_feed(reg, url,feed)
        #2. search
        miro.tab_search(reg, term)
        self.assertTrue(reg.m.exists(title))
        self.assertFalse(reg.m.exists("Flip"))
        miro.click_sidebar_tab(reg, "Videos")
        reg.s.click(feed)
        self.assertTrue(reg.mtb.exists(term.upper()))
        self.assertTrue(reg.m.exists(title))
        self.assertFalse(reg.m.exists("Flip"))
        #4. cleanup
        miro.delete_feed(reg, "stupid")
Пример #2
0
    def test_112(self):
        """http://litmus.pculture.org/show_test.cgi?id=112 download errors

        1. Add feed
        2. Download All
        3. Verify error messages
        """
        reg = MiroRegions()
        miro = MiroApp()
        feed_url = "http://participatoryculture.org/feeds_test/feed13.rss"
        feed_name = "Feed"

        error_types = {"Server Closes Connection": "no_connection.png",
                       "File not found": "file_not_found.png",
                       "503 Error": "no_connection.png",
                       "Host not found": "unknown_host.png",
                       "HTTP error": "http_error.png",
                       "Timeout error": "no_connection.png",
                       }
        miro.add_feed(reg, feed_url, feed_name)
        miro.set_podcast_autodownload(reg, setting="All")
        time.sleep(10)
        for error, image in error_types.iteritems():
                miro.tab_search(reg, error)
                assert reg.m.exists(Pattern(image).similar(0.6),60)
        miro.delete_feed(reg, feed_name)
Пример #3
0
    def test_78(self):
        """http://litmus.pculture.org/show_test.cgi?id=78 Menu New Search Feed.

        1. Add list of guide feeds (Static List)
        2. From Sidebar -> New Search feed, create saved search channel
        3. Verify Search saved
        4. Cleanup

        """
        reg = MiroRegions() 
        miro = MiroApp()
        
        url = "http://pculture.org/feeds_test/list-of-guide-feeds.xml"
        feed = "Static"
        term = "touring"
        term2 = "Biking"
        title = "Travelling Two"
        dummy_feed_url = "http://pculture.org/feeds_test/2stupidvideos.xml"
        
        #1. add feed
        miro.add_feed(reg, url,feed)
        miro.add_feed(reg, dummy_feed_url,"TWO STUPID")
        #2. search
        miro.new_search_feed(reg, term,radio="Podcast",source=feed)
        time.sleep(5)
                        
        #3. verify search saved
        miro.click_last_podcast(reg)
        self.assertTrue(reg.m.exists(term2))
        
        #4. cleanup
        miro.click_remove_podcast(reg)
        miro.remove_confirm(reg, action="remove")
        miro.delete_feed(reg, "Static List")
Пример #4
0
    def test_215(self):
        """http://litmus.pculture.org/show_test.cgi?id=215 Feed search, saved search feed

        1. Add list of guide feeds (Static List)
        2. Perform a search and save it.
        3. Verify Search saved
        4. Cleanup

        """
        reg = MiroRegions() 
        miro = MiroApp()
        
        url = "http://pculture.org/feeds_test/list-of-guide-feeds.xml"
        feed = "Static"
        term = "Gimp"
        title = "GimpKnowHow"
        
        #1. add feed
        miro.add_feed(reg, url, feed)
        #2. search
        miro.tab_search(reg, term)
        reg.mtb.click("button_save_as_podcast.png")
        #3. verify search saved
        miro.click_last_podcast(reg)
        #4. cleanup
        type(Key.DELETE)
        #Last chance to verify Gimp is the saved search feed.
        self.assertTrue(reg.m.exists("GIMP"),5)
        miro.remove_confirm(reg, action="remove")
        miro.delete_feed(reg, "Static List")
        miro.handle_crash_dialog('215', db=False, test=False)
Пример #5
0
    def test_213(self):
        """http://litmus.pculture.org/show_test.cgi?id=213 Feed search, delete key.

        1. Add 2-stupid-videos feed
        2. Perform a search
        3. Type in search box the delete key 
        4. Cleanup

        """
        reg = MiroRegions() 
        miro = MiroApp()
        
        url = "http://pculture.org/feeds_test/2stupidvideos.xml"
        feed = "TWO STUPID"
        title = "Flip"
        term = "dinosaur"
        
        #1. add feed
        miro.add_feed(reg, url, feed)
        #2. search
        miro.tab_search(reg, term)
        self.assertFalse(reg.m.exists(title, 5))
        reg.mtb.click(term.upper())
        for x in range(0,8):
            type(Key.LEFT)
        
        for x in range(0,8):
            type(Key.DELETE)

        self.assertTrue(reg.m.exists(title))
        #4. cleanup
        miro.delete_feed(reg, feed)
Пример #6
0
    def test_338(self):
        """http://litmus.pculture.org/show_test.cgi?id=338 delete feed with dl items.

        Litmus Test Title:: 338 - channels delete a feed with downloads in progress
        Description: 
        1. Add the 3-blip-videos feed. Start items downloading  
        2. Remove the feed and verify downloads are removed.
        """

      

        #set the search regions
        reg = MiroRegions() 
        miro = MiroApp()

        url = "http://pculture.org/feeds_test/3blipvideos.xml"
        feed = "ThreeBlip"

        #1. Add the feed and start dl
        miro.cancel_all_downloads(reg)
        miro.add_feed(reg, url,feed)
        miro.download_all_items(reg)
        time.sleep(2)
        miro.confirm_download_started(reg, "The Joo")
        miro.delete_feed(reg, feed)
        time.sleep(5)
        if reg.s.exists("Downloading",5):
            self.fail("Downloading tab still present")
Пример #7
0
    def test_458(self):
        """http://litmus.pculture.org/show_test.cgi?id=458 edit blank item description

        1. add TWO STUPID feed
        2. download the Flip Faceitem
        3. Edit item description
        4. Cleanup
        """
        
        reg = MiroRegions() 
        miro = MiroApp()
        time.sleep(5)
        url = "http://pculture.org/feeds_test/2stupidvideos.xml"
        feed = "TWO STUPID"
        title = "Flip" # item title updates when download completes
             
        #add feed and download flip face item
        miro.add_feed(reg, url,feed)
        miro.toggle_normal(reg)
        miro.tab_search(reg, title)
        if reg.m.exists("button_download.png",10):
            click(reg.m.getLastMatch())
        miro.wait_for_item_in_tab(reg, "Videos",item=title)
        reg.m.click(title)
        miro.edit_item_metadata(reg, meta_field="about",meta_value="Blank description edited")
        miro.tab_search(reg, "blank description")
        if reg.m.exists(title):
            miro.log_result("656","test_458")           
        else:
            miro.log_result("656","test_458",status="fail")
        #cleanup
        miro.delete_feed(reg, feed)
Пример #8
0
    def test_214(self):
        """http://litmus.pculture.org/show_test.cgi?id=214 Feed search, search with spaces

        1. Add 3 blip videos feed
        2. Perform a search with spaces
        3. Verify Search saved
        4. Cleanup

        """
        reg = MiroRegions() 
        miro = MiroApp()
        
        url = "http://pculture.org/feeds_test/3blipvideos.xml"
        feed = "ThreeBlip"
        term = "strange creature"
        title = "Joo Joo"
        
        #1. add feed
        miro.add_feed(reg, url,feed)
        #2. search
        miro.tab_search(reg, term)
        reg.mtb.click("button_save_as_podcast.png")
        #3. verify search saved
        miro.click_last_podcast(reg)
        miro.tab_search(reg, term,confirm_present=True)
        
        #4. cleanup
        miro.click_remove_podcast(reg)
        miro.remove_confirm(reg, action="remove")
        miro.delete_feed(reg, "blip")
        miro.delete_feed(reg, feed)
Пример #9
0
    def test_720(self):
        """http://litmus.pculture.org/show_test.cgi?id=720 Menu New Search Feed.

        1. Add list of guide feeds (Static List)
        2. Search in the tab
        3. From Sidebar -> New Search feed, create saved search channel
        4. Verify Search saved
        5. Cleanup

        """
        reg = MiroRegions() 
        miro = MiroApp()
        
        url = "http://pculture.org/feeds_test/list-of-guide-feeds.xml"
        feed = "Static"
        term = "Voice"
                
        #1. add feed
        miro.add_feed(reg, url,feed)
        miro.tab_search(reg, term)
        #2. search
        miro.new_search_feed(reg, term, radio="Podcast", source=feed, defaults=True)
                        
        #3. verify search saved
        miro.click_last_podcast(reg)
        self.assertTrue(reg.m.exists(term, 45))
        
        #4. cleanup
        miro.click_remove_podcast(reg)
        miro.remove_confirm(reg, action="remove")
        miro.delete_feed(reg, "Static List")
Пример #10
0
    def test_441(self):
        """http://litmus.pculture.org/show_test.cgi?id=441 delete podcast item outside of miro

        1. add TWO STUPID feed
        2. download the Flip Faceitem
        3. restart miro
        4. delete the item
        5. restart miro
        6. verify item still deleted
        """
        reg = MiroRegions() 
        miro = MiroApp()

        #Set Global Preferences

        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        general_tab = prefs.open_tab("General")
        general_tab.close_prefs()
   
        url = "http://qa.pculture.org/feeds_test/2stupidvideos.xml"
        feed = "TWO STUPID"
        title = "Flip" # item title updates when download completes
             
        #add feed and download flip face item
        miro.add_feed(reg, url,feed)
        miro.toggle_normal(reg)
        miro.tab_search(reg, title)
        if reg.m.exists("button_download.png",10):
            click(reg.m.getLastMatch())
        miro.wait_for_item_in_tab(reg, tab="Videos",item=title)
        reg.m.find(title)
        reg.m.click(title)
        reg.mtb.click("tabsearch_clear.png")
        filepath = miro.store_item_path(reg)
        if os.path.exists(filepath):
            print "able to verify on os level"
            found_file = True
        miro.tab_search(reg, title)
        reg.m.click(title)
        type(Key.DELETE)

        if found_file == True:
            if os.path.exists(filepath):
                self.fail("file not deleted from filesystem")
        else:
            miro.quit_miro()
            miro.restart_miro()
            miro.click_podcast(reg, feed)
            miro.tab_search(reg, term)
            if not reg.m.exists(Pattern("button_download.png")):
                self.fail("no download button, file not deleted")
            else:
                reg.m.click(Pattern("button_download.png"))
            if miro.confirm_download_started(reg, title) != "in_progress":
                self.fail("item not properely deleted")    
        #cleanup
        miro.delete_feed(reg, feed)
Пример #11
0
    def test_728(self):
        """http://litmus.pculture.org/show_test.cgi?id=728 edit metadata for mulitple items

        1. add Static List feed
        2. download the Earth Eats item
        3. Edit item metadata
       

        """
        reg = MiroRegions() 
        miro = MiroApp()
        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        general_tab = prefs.open_tab("General")
        general_tab.show_audio_in_music("on")
        general_tab.close_prefs()
        
        url = "http://qa.pculture.org/feeds_test/list-of-guide-feeds.xml"
        feed = "Static"
        term = "Earth Eats"
        title = "Mushroom" # item title updates when download completes
        new_type = "Video"

        edit_itemlist = [
            ["name", "Earth Day Everyday", "647"],
            ["artist", "Oliver and Katerina", "648"],
            ["album", "Barki Barks", "649"],
            ["genre", "family", "650"],
            ["track_num" ,"1", "673"],
            ["track_of" ,"2", "673"],
            ["year", "2010", "655"],
            ["rating", "5", "651"],
            ]
        
        #start clean
        miro.delete_feed(reg, feed)
        #add feed and download earth eats item
        miro.add_feed(reg, url,feed)
        miro.toggle_normal(reg)
        miro.tab_search(reg, term)
        if reg.m.exists("button_download.png",10):
            click(reg.m.getLastMatch())
        miro.wait_for_item_in_tab(reg, "Music",item=title)
        reg.m.find(title)
        reg.m.click(title)
        reg.mtb.click("tabsearch_clear.png")
        for x in edit_itemlist:
            miro.edit_item_metadata(reg, meta_field=x[0],meta_value=x[1])
            try:
                miro.log_result(x[2],"test_647")
            finally:
                time.sleep(2)
        if not miro.tab_search(reg, "Earth Day",confirm_present=True) == True:
            self.fail("new title not saved")
        #cleanup
        miro.delete_feed(reg, feed)
Пример #12
0
    def test_24(self):
        """http://litmus.pculture.org/show_test.cgi?id=24 edit remembered search.

        1. Add 2-stupid-videos feed
        2. Perform a search
        3. Type in search box the delete key 
        4. Cleanup

        """
        reg = MiroRegions() 
        miro = MiroApp()
        
        url = "http://pculture.org/feeds_test/2stupidvideos.xml"
        feed = "TWO STUPID"
        term = "Face"
        title = "Flip"
        
        #1. add feed
        miro.add_feed(reg, url,feed)
        miro.set_podcast_autodownload(reg, setting="All")
        #2. search
        miro.tab_search(reg, term)
        self.assertTrue(reg.m.exists(title))

        url2 = "http://pculture.org/feeds_test/list-of-guide-feeds.xml"
        feed2 = "Static"
        term2 = "FilmWeek"
        miro.add_feed(reg, url2,feed2)
        miro.tab_search(reg, "Brooklyn")
        miro.wait_for_item_in_tab(reg, "Videos",title)
        reg.m.click(title)
        type(Key.ENTER)
        time.sleep(2)
        type(" ")
        self.assertTrue(exists("playback_controls.png"))
        miro.shortcut("d")

        reg.s.click(feed2)
        self.assertTrue(reg.mtb.exists("BROOKLYN"))
        miro.tab_search(reg, term2)
        reg.mtb.click("button_save_as_podcast.png")

        miro.click_last_podcast(reg)
        miro.tab_search(reg, term2,confirm_present=True)
        miro.clear_search(reg)
        time.sleep(3)
        if not reg.mtb.exists(term2.upper()):
            miro.log_result("324","test_24",status="pass")
       

        #4. cleanup
        miro.delete_feed(reg, "stupid")
        miro.click_last_podcast(reg)
        miro.delete_current_selection(reg)
        miro.delete_feed(reg, "Static List")
Пример #13
0
    def test_657(self):
        """http://litmus.pculture.org/show_test.cgi?id=657 edit multiple fields

        1. add Static List feed
        2. download the Earth Eats item
        3. Edit item metadata

        """
        
        reg = MiroRegions()
        miro = MiroApp()
        time.sleep(5)
        url = "http://ringtales.com/nyrss.xml"
        feed = "The New"
        title = "Cat" 

        new_metadata_list = [
            ["show","Animated Cartoons", "658"],
            ["episode_id","nya", "670"],
            ["season_no","25", "671"],
            ["episode_no","43", "672"],
            ["video_kind","Clip", "652"],
            ]
        
        try:       
            
            #start clean
            miro.delete_feed(reg, feed)
            #add feed and download earth eats item
            miro.add_feed(reg, url,feed)
            miro.toggle_normal(reg)
            miro.tab_search(reg, title)
            if reg.m.exists("button_download.png",10):
                click(reg.m.getLastMatch())
            miro.wait_for_item_in_tab(reg, "Videos",item=title)
            miro.click_podcast(reg, feed)
            miro.tab_search(reg, title)
            reg.m.click(title)
            miro.edit_item_video_metadata_bulk(reg, new_metadata_list)
            time.sleep(2)
            miro.click_sidebar_tab(reg, "Videos")
            miro.tab_search(reg, title)
            reg.mtb.click("Clip")
            if reg.m.exists(title):
                reg.mtb.click("All")
            else:
                self.fail("item not found in Clips filter")
        
        finally:
            miro.quit_miro()
            myLib.config.set_def_db_and_prefs()
Пример #14
0
    def test_361(self):
        """http://litmus.pculture.org/show_test.cgi?id=361 edit item video to audio.

        1. add 3-blip-videos feed
        2. download the Joo Joo
        3. Edit item from Video to Audio
        4. Verify item played as audio item

        """
        reg = MiroRegions() 
        miro = MiroApp()
        time.sleep(5)
        url = "http://qa.pculture.org/feeds_test/MixedCats.xml"
        feed = "MIXED"
        title = "Tongue"
        new_type = "Music"
        old_type = "Video"

        #Set Global Preferences
        
        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        general_tab = prefs.open_tab("General")
        general_tab.show_audio_in_music("on")
        general_tab.show_videos_in_videos("on")
        podcasts_tab = prefs.open_tab("Podcasts")
        podcasts_tab.autodownload_setting("Off")
        podcasts_tab.close_prefs()
        
        #start clean
        miro.delete_feed(reg, feed)
        #add feed and download joo joo item
        miro.add_feed(reg, url,feed)
        miro.tab_search(reg, title)
        if reg.m.exists("button_download.png",10):
            click(reg.m.getLastMatch())
        miro.wait_for_item_in_tab(reg, "Videos", item=title)
        reg.m.find(title)
        reg.m.click(title)
        reg.mtb.click("tabsearch_clear.png")
        miro.edit_item_type(reg, new_type, old_type)
        #locate item in audio tab and verify playback
        miro.wait_for_item_in_tab(reg, tab="Music",item=title)
        reg.m.click(title)        
        type(' ') #use spacebar to start playback
        self.assertTrue(miro.verify_audio_playback(reg, title))
        miro.stop_audio_playback(reg, title)
       
        #cleanup
        miro.delete_feed(reg, feed)
Пример #15
0
    def test_108(self):
        """http://litmus.pculture.org/show_test.cgi?id=108 playback through unplayed items.

        1. add a feed url feed of small items
        2. download a few items 
        3. verify unplayed - playback through list
        4. verify marked as unplayed.

        """

        url_path = os.path.join(os.getenv("PCF_TEST_HOME"),"Miro","TestData","ShortCats.xml")
        url = "file:///"+url_path
        feed = "Short Cats"
##        url = "http://qa.pculture.org/feeds_test/2stupidvideos.xml"
##        feed = "TWO STUPID"
        
        reg = MiroRegions() 
        miro = MiroApp()


        #Set Global Preferences
        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        playback_tab = prefs.open_tab("Playback")
        playback_tab.play_continuous("on", "Podcast")
        playback_tab.close_prefs()
        
        miro.add_feed(reg, url, feed)
        miro.set_podcast_autodownload(reg, setting="All")
        time.sleep(15)
        miro.set_podcast_autodownload(reg, setting="Off")
        if reg.s.exists("Downloading"):
            reg.s.waitVanish("Downloading")
        miro.click_sidebar_tab(reg, "Videos")
        miro.toggle_normal(reg)
        reg.m.wait("item_play_unplayed.png")
        if reg.m.exists("item_play_unplayed.png"):
            find(Pattern("sort_name_normal.png"))
            doubleClick(getLastMatch().below(100))
            wait(Pattern("playback_bar_video.png"),15)
        else:
            self.fail("no unplayed badges found")
        if exists(Pattern("playback_bar_video.png")):
            print "playback started"
            time.sleep(60)
            waitVanish(Pattern("playback_bar_video.png"))
        if reg.m.exists("item_play_unplayed.png"):
            self.fail("items not marked as unplayed")
Пример #16
0
    def test_362(self):
        """http://litmus.pculture.org/show_test.cgi?id=362 edit item music to video

        1. add Feed
        2. download Paris mp3
        3. Edit item from Audio to Video
        4. Verify item played as video item

        """
        reg = MiroRegions() 
        miro = MiroApp()
        time.sleep(5)
        url = "http://qa.pculture.org/feeds_test/MixedCats.xml"
        feed = "MIXED"
        term = "Paris"
        title = "Laren"
        new_type = "Video"
        old_type = "Music"
        #Set Global Preferences
        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        general_tab = prefs.open_tab("General")
        general_tab.show_audio_in_music("on")
        general_tab.show_videos_in_videos("on")
        podcasts_tab = prefs.open_tab("Podcasts")
        podcasts_tab.autodownload_setting("Off")
        podcasts_tab.close_prefs()

        
        #add feed and download joo joo item
        miro.add_feed(reg, url,feed)
        miro.tab_search(reg, term)
        if reg.m.exists("button_download.png",10):
            click(reg.m.getLastMatch())
        miro.wait_for_item_in_tab(reg, "Music",item=title)
        reg.m.find(title)
        reg.m.click(title)
        reg.mtb.click("tabsearch_clear.png")
        miro.edit_item_type(reg, new_type, old_type)
        #locate item in audio tab and verify playback
        miro.wait_for_item_in_tab(reg, tab="Video",item=title)
        reg.m.doubleClick(title)
        miro.verify_video_playback(reg)
        miro.quit_miro()
        miro.restart_miro()
        miro.wait_for_item_in_tab(reg, tab="Video",item=title)
        #cleanup
        miro.delete_feed(reg, feed)
Пример #17
0
    def test_138(self): #shortened as there no more feed counter and can't count too much stuff.
        """http://litmus.pculture.org/show_test.cgi?id=138 clear out old items.

        Litmus Test Title:: 138 Channels - clear out old items 
        Description: 
         1. Add a feed that adds five new items each time it's updated.
         2. Update the feed to add new items.
         3. Modify old items settings to verify items cleared.
         4. Cleanup

        """
        
        #set the search regions
        reg = MiroRegions() 
        miro = MiroApp()        
        url = "http://bluesock.org/~willg/cgi-bin/newitemsfeed.cgi"
        feed = "my feed"
        miro.add_feed(reg, url,feed)
        miro.get_podcasts_region(reg)

        
        miro.tab_search(reg, "my feed")
        miro.toggle_list(reg)
        
        miro.count_images(reg, img="my feed",region="list",num_expected=5)
        miro.click_podcast(reg, feed)
        miro.shortcut("r")
        time.sleep(10)
        miro.get_podcasts_region(reg)
        if miro.count_images(reg, img="my feed",region="list",num_expected=10) == 10:
            miro.log_result("99","test_92") #verifies update podcast shortcut
        miro.click_podcast(reg, feed)
        for x in range(0,3):
            miro.shortcut("r")
            time.sleep(3)
        miro.open_podcast_settings(reg)
        miro.change_podcast_settings(reg, option="Podcast Items",setting="Keep 0")
        time.sleep(2)
        miro.get_podcasts_region(reg)
        miro.count_images(reg, img="my feed",region="list",num_expected=5)
        #4. cleanup
        miro.delete_feed(reg, "my feed") 
Пример #18
0
    def test_363(self):
        """http://litmus.pculture.org/show_test.cgi?id=363 edit item metadata

        1. add Static List feed
        2. download the Earth Eats item
        3. Edit item metadata
        4. Verify item played as audio item

        """
        reg = MiroRegions() 
        miro = MiroApp()
        time.sleep(5)
        url = "http://qa.pculture.org/feeds_test/list-of-guide-feeds.xml"
        feed = "Static"
        term = "Earth Eats"
        title = "Mushroom" 
        new_type = "Video"
        #Set Global Preferences
        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        general_tab = prefs.open_tab("General")
        general_tab.show_audio_in_music("on")
        general_tab.close_prefs()

        
        miro.delete_feed(reg, feed)
        
        #add feed and download earth eats item
        miro.add_feed(reg, url,feed)
        miro.toggle_normal(reg)
        miro.tab_search(reg, title=term)
        if reg.m.exists("button_download.png",10):
            click(reg.m.getLastMatch())
        miro.wait_for_item_in_tab(reg, "Music", item=title)
        reg.m.find(title)
        reg.m.click(title)
        reg.mtb.click("tabsearch_clear.png")
        miro.edit_item_metadata(reg, meta_field="about",meta_value="hoovercraft full of eels")
        miro.tab_search(reg, "hoovercraft eels")
        if not reg.m.exists(title):
            self.fail("can not verify description edited")
        miro.delete_feed(reg, feed)
Пример #19
0
    def test_18453_764(self):
        """http://litmus.pculture.org/show_test.cgi?id=764 vimeo likes feed dl.

        1. Add feed
        2. Download item
        3. Verify download completes
        4. Check title display via screenshot
        5. Verify playback

        """
        feed_url = "http://vimeo.com/habi/likes/rss"
        feed_name = "David"
        item_title = "glove"
        item_image = "vimeo-glove.png"
        reg = MiroRegions()
        miro = MiroApp()
        miro.add_feed(reg, feed_url, feed_name)
        miro.tab_search(reg, item_title)
        miro.download_all_items(reg)
        assert download_playback_check_title(reg, miro, item_title, item_image)
        miro.delete_feed(reg, feed_name)
Пример #20
0
    def test_18656_763(self):
        """http://litmus.pculture.org/show_test.cgi?id=763 youtube feed dl.

        1. Add feed
        2. Download item
        3. Verify download completes
        4. Check title display via screenshot
        5. Verify playback

        """
        url_path = os.path.join(os.getenv("PCF_TEST_HOME"),"Miro","TestData","youtube-feed.rss")
        feed_url = "file:///"+url_path
        feed_name = "AL JAZEERA"
        item_title = "Alarm"
        item_image = "youtube_alarm_spreads.png"
        reg = MiroRegions()
        miro = MiroApp()
        miro.add_feed(reg, feed_url, feed_name)
        miro.tab_search(reg, item_title)
        miro.download_all_items(reg)
        assert download_playback_check_title(reg, miro, item_title, item_image)
        miro.delete_feed(reg, feed_name)
Пример #21
0
    def test_18656_764(self):
        """http://litmus.pculture.org/show_test.cgi?id=764 vimeo feed dl.

        1. Add feed
        2. Download item
        3. Verify download completes
        4. Check title display via screenshot
        5. Verify playback

        """
        url_path = os.path.join(os.getenv("PCF_TEST_HOME"),"Miro","TestData","vimeo-feed")
        feed_url = "file:///"+url_path
        feed_name = "ONE DAY"
        item_title = "Jellyfish"
        item_image = "vimeo-jellyfish.png"
        reg = MiroRegions()
        miro = MiroApp()
        miro.add_feed(reg, feed_url, feed_name)
        miro.tab_search(reg, item_title)
        miro.download_all_items(reg)
        assert download_playback_check_title(reg, miro, item_title, item_image)
        miro.delete_feed(reg, feed_name)
Пример #22
0
    def test_18656_765(self):
        """http://litmus.pculture.org/show_test.cgi?id=764 itunes feed dl.

        1. Add feed
        2. Download item
        3. Verify download completes
        4. Check title display via screenshot
        5. Verify playback

        """
        url_path = os.path.join(os.getenv("PCF_TEST_HOME"),"Miro","TestData","dilbert-feed.xml")
        feed_url = "file:///"+url_path
        feed_name = "Dilbert"
        item_title = "Survey"
        item_image = "dilbert_survey_results.png"
        reg = MiroRegions()
        miro = MiroApp()
        miro.add_feed(reg, feed_url, feed_name)
        miro.tab_search(reg, item_title)
        miro.download_all_items(reg)
        assert download_playback_check_title(reg, miro, item_title, item_image)
        miro.delete_feed(reg, feed_name)
Пример #23
0
    def test_14289_644(self):
        """http://litmus.pculture.org/show_test.cgi?id=644 feed items with non-ascii chars.

        1. Add feed
        2. Download item
        3. Verify download completes
        4. Check title display via screenshot
        5. Verify playback

        """
        url_path = os.path.join(os.getenv("PCF_TEST_HOME"),"Miro","TestData","dilbert-feed.xml")
        feed_url = "http://gdata.youtube.com/feeds/api/users/4001v63/uploads"
        feed_name = "Uploads"
        item_title = "kerta"
        item_image = "non_ascii_item.png"
        reg = MiroRegions()
        miro = MiroApp()
        miro.add_feed(reg, feed_url, feed_name)
        miro.tab_search(reg, item_title)
        miro.download_all_items(reg)
        assert download_playback_check_title(reg, miro, item_title, item_image)
        miro.delete_feed(reg, feed_name)
Пример #24
0
    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":"******",
                     "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="******", 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")
Пример #25
0
    def test_641(self):
        """http://litmus.pculture.org/show_test.cgi?id=641, delete with invalid url.
       
            Litmus Test Title:: 641 - Deleting podcast with invalid urls
            Steps to Perform:
            1. Select "Add podcast" from Sidebar menu.
            2. Enter URL http://subscribe.getmiro.com/?url1=http%3A%2F%2Fparticipatoryculture.org%2Ffeeds_test%2Ffeed1.rss
            3. Click "Create Podcast" button
            4. Click "Yes" in "This podcast is not compatible with Miro" window
            5. While the podcast is downloading, right click on it and select "Remove" option.
        """

        reg = MiroRegions() 
        miro = MiroApp()
        url = "http://subscribe.getmiro.com/?url1=http%3A%2F%2Fparticipatoryculture.org%2Ffeeds_test%2Ffeed1.rss"
        feed = "invalid"        
        #Set Global Preferences
        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        podcasts_tab = prefs.open_tab("Podcasts")
        podcasts_tab.autodownload_setting("All")
        podcasts_tab.close_prefs()
       
        miro.add_feed(reg, url, feed, click_feed=False)        
        if exists("anyway",45):
            type(Key.ENTER)
        miro.click_last_podcast(reg)
        type(Key.DELETE)
        miro.remove_confirm(reg, "remove")
        #Reset autodownload preferences
        #Set Global Preferences
        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        podcasts_tab = prefs.open_tab("Podcasts")
        podcasts_tab.autodownload_setting("Off")
        podcasts_tab.close_prefs()
Пример #26
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
        """

        
        #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")
Пример #27
0
    def test_122(self):
        """http://litmus.pculture.org/show_test.cgi?id=122 item click actions, normal view.

        1. add 3-blip-videos feed
        2. download the Joo Joo
        3. verify varios item click scenerios

        """
        reg = MiroRegions() 
        miro = MiroApp()
        time.sleep(5)
        url = "http://pculture.org/feeds_test/3blipvideos.xml"
        feed = "ThreeBlip"
        title1 = "The Joo"
        title2 = "York"
        title3 = "Accessing"
        miro.delete_feed(reg, feed)


        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        podcasts_tab = prefs.open_tab("Podcasts")
        podcasts_tab.autodownload_setting("Off")
        podcasts_tab.default_view_setting("Standard")
        podcasts_tab.close_prefs()

        #add feed and download joo joo item
        miro.add_feed(reg, url,feed)
        miro.tab_search(reg, title1)
        if reg.m.exists("button_download.png",10):
            click(reg.m.getLastMatch())

        miro.click_podcast(reg, feed)
        miro.tab_search(reg, title2,confirm_present=True)

        #double-click starts download
        doubleClick(title2)
        if miro.confirm_download_started(reg, title=title2) == "in_progress":
            miro.log_result("122","normal view double-click starts download")
        else:
            self.fail("normal view double-click starts download, failed")
        #double-click pauses download
        miro.click_podcast(reg, feed)
        doubleClick(title2)
        if exists("item-renderer-download-resume.png"):
            miro.log_result("122","normal view double-click pauses download")
        else:
            self.fail("normal view double-click pause download, failed")
        #double-click resumes download
        doubleClick(title2)
        if exists("item-renderer-download-pause.png"):
            miro.log_result("122","normal view double-click resume download")
        else:
            self.fail("normal view double-click resume download, failed")
        #double-click starts playback
        miro.wait_for_item_in_tab(reg, tab="Videos",item=title1)
        miro.click_podcast(reg, feed)
        miro.tab_search(reg, title1)
        doubleClick(title1)
        if exists(Pattern("playback_bar_video.png")):
            miro.log_result("122","normal view double-click starts playback")
        else:
            self.fail("normal view double-click start playback, failed")
        miro.verify_video_playback(reg)

        #single click thumb starts download
        miro.tab_search(reg, title3)
        if reg.m.exists("thumb-default-video.png"):
            print "using default thumb"
            click(reg.m.getLastMatch())
        else:
            print "can't find thumb, best guess"
            reg.m.find(title1)
            click(reg.m.getLastMatch().left(50))
        if miro.confirm_download_started(reg, title=title3) == "in_progress":
            miro.log_result("122","normal view click starts download")
        else:
            self.fail("normal view double-click starts download, failed")
        #single click thumb starts playback
        miro.click_podcast(reg, feed)
        miro.tab_search(reg, title1)
        if reg.m.exists("thumb-default-video.png"):
            print "using default thumb"
            click(reg.m.getLastMatch())
        elif reg.m.exists("thumb-joojoo.png"):
            print "found joo joo thumb"
            click(reg.m.getLastMatch())
        else:
            print "can't find thumb, best guess"
            reg.m.find(title1)
            click(reg.m.getLastMatch().left(50))
        if exists("playback_bar_video.png"):
            miro.log_result("122","normal view double-click starts playback")
        else:
            self.fail("normal view double-click start playback, failed")
        miro.verify_video_playback(reg)   
        #cleanup
        miro.delete_feed(reg, feed)
Пример #28
0
    def test_725(self):
        """http://litmus.pculture.org/show_test.cgi?id=725 item click actions, list view.

        1. add 3-blip-videos feed
        2. download the Joo Joo
        3. verify varios item click scenerios

        """
        reg = MiroRegions() 
        miro = MiroApp()
        time.sleep(5)
        url = "http://pculture.org/feeds_test/3blipvideos.xml"
        feed = "ThreeBlip"
        title1 = "The Joo"
        title2 = "York"
        title3 = "Accessing"
        miro.delete_feed(reg, feed)
        #Set Global Preferences
        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        podcasts_tab = prefs.open_tab("Podcasts")
        podcasts_tab.autodownload_setting("Off")
        podcasts_tab.default_view_setting("List")
        podcasts_tab.close_prefs()
        

        time.sleep(2)      
        #add feed and download joo joo item
        miro.add_feed(reg, url,feed)
        miro.tab_search(reg, title1)
        #double-click starts download
        reg.m.find(title1)
        title_loc = reg.m.getLastMatch()
        doubleClick(title_loc)
        if reg.m.exists("video-download-pause.png"):
            miro.log_result("122","list view double-click starts download")
        else:
            self.fail("list view double-click starts download, failed")
        #double-click pauses download
        doubleClick(title_loc)
        if reg.m.exists("video-download-resume.png"):
            miro.log_result("122","list view double-click pauses download")
        else:
            self.fail("list view double-click pause download, failed")
        #double-click resumes download
        doubleClick(title_loc)
        if exists("video-download-pause.png"):
            miro.log_result("122","list view double-click resumes download")
        else:
            self.fail("list view double-click resume download, failed")
        #double-click starts playback
        miro.wait_for_item_in_tab(reg, tab="Videos",item=title1)
        miro.click_podcast(reg, feed)
        miro.tab_search(reg, title1)
        doubleClick(title1)
        if exists(Pattern("playback_bar_video.png")):
            miro.log_result("122","list view double-click starts playback")
        else:
            self.fail("list view double-click start playback, failed")
        miro.verify_video_playback(reg)
        #cleanup
        miro.delete_feed(reg, feed)
Пример #29
0
    def test_117(self):
        """http://litmus.pculture.org/show_test.cgi?id=117 delete multiple feeds then cancel.

        Litmus Test Title:: 117 - delete multiple feeds then cancel
        Description: 
        1. Add several feeds from list of guide feeds
        2. Select them all
        3. Delete, the cancel the delete
        4. Cleanup
        """
        
        #set the search regions
        reg = MiroRegions() 
        miro = MiroApp()
        
        #Set Global Preferences
        miro.open_prefs(reg)
        prefs = PreferencesPanel()
        podcasts_tab = prefs.open_tab("Podcasts")
        podcasts_tab.autodownload_setting("Off")
        podcasts_tab.default_view_setting("Standard")
        podcasts_tab.close_prefs()
     
        url = "http://pculture.org/feeds_test/list-of-guide-feeds.xml"
        feed = "Static"
        feedlist = ["Center", "Earth"]

        #1. Add the feed and start dl
        miro.add_feed(reg, url,feed)
        for f in feedlist:
            miro.tab_search(reg, f)
            self.assertTrue(reg.m.exists("Add this"))
            reg.m.click("Add this")
            time.sleep(4)
        miro.tab_search(reg, "")
        miro.toggle_normal(reg)

        p = miro.get_podcasts_region(reg)
        miro.click_sidebar_tab(reg, "Music")
        miro.click_podcast(reg, feed)            
        #2. Select them all
       
        keyDown(Key.SHIFT)  
        for x in feedlist:
            if p.exists(x):
                p.click(x)
            else:
                print "could not find feed" +str(x)
            time.sleep(2)
        keyUp(Key.SHIFT)
        #3. Delete then cancel.  Verify still exists Static List
        if reg.m.exists("Delete",4) or reg.m.exists("button_mv_delete_all.png",4):
            click(reg.m.getLastMatch())
        else:
            self.fail("Can't find Delete All button in main view")
        miro.remove_confirm(reg, "cancel")
        p = miro.get_podcasts_region(reg)
        time.sleep(5)
        self.assertTrue(p.exists("Static",5))
        #4. Cleanup
        feedlist.append("Static")
        for x in feedlist:
            print x
            miro.delete_feed(reg, x)