status-react/test/appium/tests/test_sanity.py
Anton Danchenko eaf9d8dce4 added additional verifications to group/one-to-one chat tests, added accessibility ids
Revert "added checkout step to Jenkinsfile"

This reverts commit 22cd1fd0214e42767ae45d6ec8376109a52605ed.

checkout to jenkinsfile
2017-09-11 15:26:08 +03:00

29 lines
1.2 KiB
Python

import pytest
from tests.basetestcase import SingleDeviceTestCase
from views.home import HomeView
@pytest.mark.sanity
class TestSanity(SingleDeviceTestCase):
@pytest.mark.parametrize("verification", ["short", "mismatch", "valid"])
def test_password(self, verification):
verifications = {"short":
{"input": "qwe1",
"outcome": "Password should be not less then 6 symbols."},
"valid":
{"input": "qwerty1234",
"outcome": "Tap here to enter your phone number & I\'ll find your friends"},
"mismatch":
{"input": "mismatch1234",
"outcome": "Password confirmation doesn\'t match password."}}
home = HomeView(self.driver)
home.request_password_icon.click()
home.type_message_edit_box.send_keys(verifications[verification]["input"])
home.confirm()
if 'short' not in verification:
home.type_message_edit_box.send_keys(verifications["valid"]["input"])
home.confirm()
home.find_text(verifications[verification]["outcome"])