def testCreateProjectFromList(self):
        app = base_cases.BaseMyHeritageTestCase()
        app.openApp()
        app.loginApp()
        app.createProject()
        app.closeAppFromMenu()

        base_cases.BaseMyHeritageTestCase.cleanUserData()
 def testPositive(self):
     app = base_cases.BaseMyHeritageTestCase()
     app.openApp()
     app.loginApp()    
     while not exists("no_projects_found.png"):
         wait(5)
      
     app.closeApp()
     base_cases.BaseMyHeritageTestCase.cleanUserData()
    def testEndToEndFlow(self):
        app = base_cases.BaseMyHeritageTestCase()
        app.openApp()
        app.signUp()
        app.closeApp()
        wait(1)
        app.openApp()
        app.loginApp()
        app.fullScreenApp()
        app.createProjectFromDropDown()
        app.addNewMemberDetails()
        while not exists(Pattern("avatar2.png").similar(0.60)):
            wait(1)
            app.closeApp()
            app.openApp()
            print "Root person was not visible"

        wait(1)
        app.addPersonalFotoFromInfoView()
        wait(1)
        Region(436, 26, 484, 626).hover(find("1430864970320.png"))
        app.addNewMember()
        app.addNewMemberDetails()
        print "Second person was not visible"
        app.addPersonalFotoFromInfoView()
        wait(1)
        app.createProjectFromDropDown()
        click("1430863291594.png")
        wait(1)
        app.viewAllProjects()
        current = Region(2, 2, 294,
                         431).find(Pattern("1430863796371.png").similar(0.75))
        click(current.above(10))
        if not exists("1430864044044.png"):
            print "Open Project button is not visible completely"
            doubleClick(current.above(10))

        while not exists(Pattern("1430896546442.png").similar(0.65)):
            if exists("1430891160748.png"):
                print "App was crashed after switching on another project by doubleClick"
                click(find(Pattern("1430891251319.png").targetOffset(-53, 0)))
                app.closeApp()
                app.openApp()
                wait(2)
                app.viewAllProjects()
                doubleClick(current.above(10))
            wait(1)

        app.addPhotos()
        app.viewAllProjects()
        click(find("1430897280186.png").below(10))
        click(find("1430890421157.png").inside().find("1430864425019.png"))
        wait(1)
        click(find("1430864481297.png").inside().find("1430864506835.png"))
        wait(1)
        app.closeAppByShotkey()
        base_cases.BaseMyHeritageTestCase.cleanUserData()
 def testSignUp(self):
     app = base_cases.BaseMyHeritageTestCase()
     app.openApp()
     #popup("App is opened. Trying to signup")
     wait(2)
     app.verifyApp()
     app.signUp()
     if (exists("exists_pwd_not_valid.png") or exists("already_auth.png")):
         click("exit.png")
         print "User is already registered"
     elif exists("no_project_found.png"):
         app.closeApp()
    def testAddPersonalFoto(self):
        app = base_cases.BaseMyHeritageTestCase()
        app.openApp()
        app.loginApp()
        app.fullScreenApp()
        app.addPersonalFotoFromInfoView()
        while not exists("added_personal_foto.png"):
            wait(1)

        print "Personal foto was added"

        app.closeAppByShotkey()
        base_cases.BaseMyHeritageTestCase.cleanUserData()
    def testAddMediaContent(self):
        app = base_cases.BaseMyHeritageTestCase()
        app.openApp()
        app.loginApp()

        app.fullScreenApp()
        app.addPhotos()

        while not exists("1430789093915.png"):
            wait(1)

        print "New foto was added"
        #app.closeApp()
        base_cases.BaseMyHeritageTestCase.cleanUserData()
Beispiel #7
0
    def testCreateNewMember(self):
        app = base_cases.BaseMyHeritageTestCase()
        app.openApp()
        app.loginApp()
        app.createProject()
        app.addMemberDetails()
        app.addNewMember()
        app.addMemberDetails()
        wait(2)
        if exists(Pattern("2_members.png").similar(0.55)):
            print "Family member was created successfully"

        app.closeAppFromMenu()
        base_cases.BaseMyHeritageTestCase.cleanUserData()
Beispiel #8
0
        def testSwitchingProject(self):
            app = base_cases.BaseMyHeritageTestCase()
            app.openApp()
            #app.loginApp()

            while not exists("project_ui_elements.png"):
                wait(1)

            if exists("add_first_person_dialog.png"):
                click(find(Pattern("cancel_button.png").similar(0.67)))
                wait(2)
            
            app.switchingProject()
            
            wait(2)
            if exists("project_ui_elements.png"):
                print "Switching between projects was successful"
            else: 
                print "Something went wrong...Switching project was failed"
            
            app.closeApp()
            base_cases.BaseMyHeritageTestCase.cleanUserData()
    def testCreateProject(self):
        app = base_cases.BaseMyHeritageTestCase()
        app.openApp()
        app.loginApp()

        while not exists("no_projects_found.png"):
            wait(3)

        print "User is logged in successfully"
        try:
            create = Region(find("create_NP.png"))
        except FindFailed:
            popup("Unable to find target Region")

        #create.highlight(1)
        click(find(Pattern("plusCreateNP.png").similar(0.62)))

        click(find("1428487586983.png"))

        click(find(Pattern("project_name.png").similar(0.59)))

        type(project_name)

        click(find("next.png"))

        wait(2)

        click(find(Pattern("done.png").similar(0.62)))

        while not exists(Pattern("person_icon.png").similar(0.54)):
            wait(1)

        click(find(Pattern("first_name.png").similar(0.62)).right(30))

        person_name = Helpers.generate_random_string()
        type(person_name)
        click(find(Pattern("last_name.png").similar(0.61)).right(30))
        person_last_name = Helpers.generate_random_string()
        type(person_last_name)

        click(find("1430142653165.png"))
        calendar = Region(find("1430142731847.png"))
        click(find(Pattern("month_drop_down.png").similar(0.61)))
        click(Pattern("value_month.png").similar(0.59))
        click(Pattern("date.png").similar(0.78))
        doubleClick(Pattern("year.png").similar(0.61))

        type("1984")

        click(find(Pattern("birth_place.png").similar(0.61)).right(30))
        birth_place = Helpers.generate_random_string()
        type(birth_place)

        click(find(Pattern("1428488759155.png").similar(0.50)))

        while not exists(Pattern("avatar2.png").similar(0.60)):
            wait(1)

        print "Root person was added"

        #exit from app after testing
        click(find(Pattern("FTBmac_menu.png").similar(0.66)))
        click(find(Pattern("SSQ.png").similar(0.60)))

        base_cases.BaseMyHeritageTestCase.cleanUserData()