blob: ae5b1cc179456c3ecda70cbea362510ecf0fabec [file] [log] [blame]
Rahul Maheshwarif7376af2018-06-11 00:46:36 -05001*** Settings ***
2
3Documentation Test OpenBMC GUI "Network settings" sub-menu of
4... "Server configuration".
5
6Resource ../../lib/resource.robot
7
8Suite Setup Launch Browser And Login OpenBMC GUI
Rahul Maheshwari43333ff2018-11-26 23:18:36 -06009Suite Teardown Close Browser
Rahul Maheshwarif7376af2018-06-11 00:46:36 -050010Test Setup Test Setup Execution
11
12*** Variables ***
13
14${xpath_select_server_configuration} //*[@id="nav__top-level"]/li[4]/button
15${xpath_select_network_settings} //a[@href='#/configuration/network']
16${xpath_hostname_input} //*[@id="net-config__mac"]
17${xpath_network_save_settings} //*[@id="configuration-network"]/form/section[3]/div[2]/button[1]
18${xpath_continue} //*[@id=""]/main/section/div/div[4]/button[2]
Anusha Dathatriac71e3f2019-07-24 00:12:59 -050019${xpath_network_config_ipv4_address} //*[@id="ipv4-address-1"]
Rahul Maheshwari88f56ec2018-06-18 05:08:40 -050020${xpath_default_gateway_input} //*[@id="net-config__domain"]
21${xpath_mac_address_input} //*[@id="net-config__host"]
Anusha Dathatriac71e3f2019-07-24 00:12:59 -050022${xpath_ipv4-address-input} //*[@id="ipv4-address-1"]
Rahul Maheshwari2d6cb192018-06-19 02:37:02 -050023${xpath_network_DHCP_button} //*[@id="configuration-network"]/form/section[2]/fieldset/div[1]/label/span
24${xpath_network_static_button} //*[@id="configuration-network"]/form/section[2]/fieldset/div[2]/label/span
Rahul Maheshwarif7376af2018-06-11 00:46:36 -050025
26*** Test Cases ***
27
28Verify Network Settings From Server Configuration
29 [Documentation] Verify ability to select "Network Settings" sub-menu option
30 ... of "Server Configuration".
31 [Tags] Verify_Network_Settings_From_Server_Configuration
32
33 Wait Until Page Contains BMC network settings
34 Page Should Contain IPV4 settings Common settings
35
36
37Verify Hostname Text Configuration
38 [Documentation] Verify hostname text is configurable from "network settings"
39 ... sub-menu.
Sivas SRR125724a2018-06-15 05:32:20 -050040 [Tags] Verify_Hostname_Text_Configuration
Rahul Maheshwarif7376af2018-06-11 00:46:36 -050041
42 Input Text ${xpath_hostname_input} witherspoon1
43 Click Element ${xpath_network_save_settings}
44 Wait Until Page Does Not Contain Element ${xpath_refresh_circle}
45 Click Element ${xpath_continue}
46 Wait Until Page Does Not Contain Element ${xpath_refresh_circle}
47 Page Should Contain witherspoon1
48
49
Rahul Maheshwari88f56ec2018-06-18 05:08:40 -050050Verify Default Gateway Editable
51 [Documentation] Verify default gateway text input allowed from "network
52 ... settings".
53 [Tags] Verify_Default_Gateway_Editable
54
55 Page Should Contain Element ${xpath_default_gateway_input}
56 Input Text ${xpath_default_gateway_input} 10.6.6.7
57
58
59Verify MAC Address Editable
60 [Documentation] Verify MAC address text input allowed from "network
61 ... settings".
62 [Tags] Verify_MAC_Address_Editable
63
64 Page Should Contain Element ${xpath_mac_address_input}
65 Input Text ${xpath_mac_address_input} 70:e2:84:14:16:6c
66
67
Rahul Maheshwari2d6cb192018-06-19 02:37:02 -050068Verify IP Address Editable With Static IP Selection
69 [Documentation] Verify IP address editable with static IP selection.
70 [Tags] Verify_IP_Address_Editable_With_Static_IP_Selection
71
72 Page Should Contain Element ${xpath_network_static_button}
73 Click Element ${xpath_network_static_button}
74 ${status}= Run Keyword And Return Status Input Text
75 ... ${xpath_ipv4-address-input} ${OPENBMC_HOST}
76 Should Be True '${status}' == '${True}'
77
78
79Verify IP Address Noneditable With DHCP IP Selection
80 [Documentation] Verify IP address noneditable with DHCP IP selection.
81 [Tags] Verify_IP_Address_Noneditable_With_DHCP_IP_Selection
82
83 Page Should Contain Element ${xpath_network_DHCP_button}
84 Click Element ${xpath_network_DHCP_button}
85 Element Should Be Disabled ${xpath_ipv4-address-input}
86
87
Rahul Maheshwarif7376af2018-06-11 00:46:36 -050088*** Keywords ***
89
90Test Setup Execution
91 [Documentation] Do test case setup tasks.
92
93 Wait Until Page Does Not Contain Element ${xpath_refresh_circle}
94 Click Element ${xpath_select_server_configuration}
95 Wait Until Page Does Not Contain Element ${xpath_refresh_circle}
96 Click Element ${xpath_select_network_settings}
97 Wait Until Page Contains Element ${xpath_network_config_ipv4_address}
98