Esempio n. 1
0
def notest_device_model():
    """ Verify the device model matches an expected value """
    system = gui()
    system.login(ip=conf.system_ip, password=conf.system_password)
    result = system.status.get_device_info()
    if conf.system_model != result['model']:
        pytest.fail("Exepected model K60i not found on status page")
Esempio n. 2
0
def test_ssid():
    """ Verify the displayed ssid matches an expected value """
    system = gui()
    system.login(ip=conf.system_ip, password=conf.system_password)
    result = system.status.get_wireless_info()
    if result['SSID'] != conf.system_ssid:
        pytest.fail("SSID did not match expeced value")
Esempio n. 3
0
def notest_hardware_version():
    """ Verify the displayed hardware version matches an expected value """
    system = gui()
    system.login(ip=conf.system_ip, password=conf.system_password)
    result = system.status.get_device_info()
    if int(conf.system_hardware_version) != int(result['hwrev']):
        pytest.fail("Exepected hardware version found on status page")
Esempio n. 4
0
def notest_ethernet_mac():
    """ Verify the displayed mac address matches an expected value """
    system = gui()
    system.login(ip=conf.system_ip, password=conf.system_password)
    result = system.status.get_device_info()
    if conf.system_mac != result['mac']:
        pytest.fail("Exepected mac not found on status page")
Esempio n. 5
0
def test_invalid_login():
    """ Try to log into the GUI with an incorrect password """
    system = gui()
    system.login(ip=conf.system_ip, password='******')
    result = system.admin.get_login_alert()
    if not "Authorization Failure" in result:
        pytest.fail("Error attempting to login with incorrect password")
Esempio n. 6
0
def test_valid_login():
    """ Log into the GUI """
    system = gui()
    system.login(ip=conf.system_ip, password=conf.system_password)
    result = system.wd.find_element_by_id('ctrl-reboot')
    if not result:
        pytest.fail("Failed to log into GUI")