How to use the gaiatest.apps.contacts.app.Contacts function in gaiatest

To help you get started, we’ve selected a few gaiatest examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github mozilla-b2g / gaia / tests / python / gaia-ui-tests / gaiatest / apps / contacts / regions / settings_form.py View on Github external
def tap_done(self):
        close = self.marionette.find_element(*self._settings_close_button_locator)
        close.tap()
        Wait(self.marionette).until(expected.element_not_displayed(close))
        from gaiatest.apps.contacts.app import Contacts
        return Contacts(self.marionette)
github mozilla-b2g / gaia / tests / python / gaia-ui-tests / gaiatest / apps / phone / app.py View on Github external
def _switch_to_contacts_frame(self):
        # This is a nested frame and we cannot locate it with AppWindowManager
        frame = Wait(self.marionette).until(
            expected.element_present(*self._contacts_frame_locator))
        self.marionette.switch_to_frame(frame)

        from gaiatest.apps.contacts.app import Contacts
        return Contacts(self.marionette)
github mozilla-b2g / gaia / tests / python / gaia-ui-tests / gaiatest / apps / contacts / regions / contact_details.py View on Github external
def tap_back(self):
        el = self.marionette.find_element(*self._details_header_locator)
        Wait(self.marionette).until(expected.element_displayed(el))
        # TODO: remove tap with coordinates after Bug 1061698 is fixed
        el.tap(25, 25)
        Wait(self.marionette).until(expected.element_not_displayed(el))
        from gaiatest.apps.contacts.app import Contacts
        return Contacts(self.marionette)
github mozilla-b2g / gaia / tests / python / gaia-ui-tests / gaiatest / apps / contacts / regions / contact_form.py View on Github external
            Wait(self.marionette).until(lambda m: self.apps.displayed_app.name != Contacts.name)
            # Fall back to the underlying app
github mozilla-b2g / gaia / tests / python / gaia-ui-tests / gaiatest / apps / contacts / regions / settings_form.py View on Github external
def tap_import_from_sim(self):
        import_from_sim = Wait(self.marionette).until(
            expected.element_present(*self._import_from_sim_button_locator))
        Wait(self.marionette).until(expected.element_displayed(import_from_sim))
        import_from_sim.tap()
        from gaiatest.apps.contacts.app import Contacts
        status_message = Wait(self.marionette).until(
            expected.element_present(*Contacts._status_message_locator))
        Wait(self.marionette).until(expected.element_displayed(status_message))
        Wait(self.marionette).until(expected.element_not_displayed(status_message))
github mozilla-b2g / gaia / tests / python / gaia-ui-tests / gaiatest / apps / system / regions / facebook.py View on Github external
def login(self, user, password):
        self.type_email(user)
        self.type_password(password)
        self.tap_submit()

        from gaiatest.apps.contacts.app import Contacts
        Contacts(self.marionette).wait_to_be_displayed()
        self.apps.switch_to_displayed_app()

        # switch to facebook import page to select the friends
        from gaiatest.apps.contacts.regions.contact_import_picker import ContactImportPicker
        return ContactImportPicker(self.marionette)
github mozilla-b2g / gaia / tests / python / gaia-ui-tests / gaiatest / apps / contacts / regions / contact_form.py View on Github external
def wait_for_done(self, return_contacts=True):
        # NewContact can be opened as an Activity from other apps. In this scenario we don't return Contacts
        if return_contacts:
            self.wait_for_element_not_displayed(*self._done_button_locator)
            from gaiatest.apps.contacts.app import Contacts
            return Contacts(self.marionette)
        else:
            from gaiatest.apps.contacts.app import Contacts
            Wait(self.marionette).until(lambda m: self.apps.displayed_app.name != Contacts.name)
            # Fall back to the underlying app
            self.apps.switch_to_displayed_app()
github mozilla-b2g / gaia / tests / python / gaia-ui-tests / gaiatest / apps / messages / regions / new_message.py View on Github external
def tap_add_recipient(self):
        self.marionette.find_element(*self._add_recipient_button_locator).tap()
        contacts_app = Contacts(self.marionette)
        contacts_app.switch_to_contacts_frame()
        return contacts_app