Example #1
0
def test_get_methods():
    user = User()
    user.login('user1_name', 'password')

    user.set_username('new_user1')
    assert user.get_username() == 'new_user1'

    user.set_mobile_phone_number('18611111111x')
    assert user.get_mobile_phone_number() == '18611111111x'

    user.set_password('new_password')
    assert user._attributes.get('passWord') == 'new_password'

    user.set_email('*****@*****.**')
    assert user.get_email() == '*****@*****.**'
Example #2
0
def test_get_methods():
    user = User()
    user.login('user1_name', 'password')

    user.set_username('new_user1')
    assert user.get_username() == 'new_user1'

    user.set_mobile_phone_number('18611111111x')
    assert user.get_mobile_phone_number() == '18611111111x'

    user.set_password('new_password')
    assert user._attributes.get('password') == 'new_password'

    user.set_email('*****@*****.**')
    assert user.get_email() == '*****@*****.**'
Example #3
0
def test_get_methods():  # type: () -> None
    user = User()
    user.login("user1_name", "password")

    user.set_username("new_user1")
    assert user.get_username() == "new_user1"

    user.set_mobile_phone_number("18611111111x")
    assert user.get_mobile_phone_number() == "18611111111x"

    user.set_password("new_password")
    assert user._attributes.get("password") == "new_password"

    user.set_email("*****@*****.**")
    assert user.get_email() == "*****@*****.**"