Added GUI automation test to verify LED ON and OFF operation

Test cases added:
  - Verify Server LED Turn On
  - Verify Server LED Turn Off

Change-Id: I15363578a8292c102b80e086d87cf20aa5a0a12d
Signed-off-by: manashsarma <manashsarma@in.ibm.com>
diff --git a/gui/gui_test/overview_menu/test_overview_menu.robot b/gui/gui_test/overview_menu/test_overview_menu.robot
index 65093a4..8ea27f4 100644
--- a/gui/gui_test/overview_menu/test_overview_menu.robot
+++ b/gui/gui_test/overview_menu/test_overview_menu.robot
@@ -20,6 +20,7 @@
 ${xpath_edit_network_settings_button}  //*[@data-test-id='overviewQuickLinks-button-networkSettings']
 ${view_all_event_logs}                 //*[@data-test-id='overviewEvents-button-eventLogs']
 ${xpath_launch_serial_over_lan}        //*[@data-test-id='overviewQuickLinks-button-solConsole']
+${xpath_led_button}                    //*[@data-test-id='overviewQuickLinks-checkbox-serverLed']
 
 *** Test Cases ***
 
@@ -131,6 +132,44 @@
     Wait Until Page Contains Element  ${xpath_sol_header}
 
 
+Verify Server LED Turn On
+    [Documentation]  Turn on server LED via GUI and verify its status via Redfish.
+    [Tags]  Verify_Server_LED_Turn_On
+
+    # Turn Off the server LED via Redfish.
+    Redfish.Patch  /redfish/v1/Systems/system  body={"IndicatorLED":"Off"}   valid_status_codes=[200, 204]
+
+    # Refresh GUI.
+    Click Element  ${xpath_refresh_button}
+    Wait Until Page Contains Element  ${xpath_led_button}
+
+    # Turn on the server LED via GUI and sleep.
+    Click Element At Coordinates  ${xpath_led_button}  0  0
+
+    # Cross check that server LED on state via Redfish.
+    ${led_status}=  Redfish.Get Attribute  /redfish/v1/Systems/system  IndicatorLED
+    Should Be True  '${led_status}' == 'Lit'
+
+
+Verify Server LED Turn Off
+    [Documentation]  Turn off server LED via GUI and verify its status via Redfish.
+    [Tags]  Verify_Server_LED_Turn_Off
+
+    # Turn On the server LED via Redfish.
+    Redfish.Patch  /redfish/v1/Systems/system  body={"IndicatorLED":"Lit"}   valid_status_codes=[200, 204]
+
+    # Refresh GUI.
+    Click Element  ${xpath_refresh_button}
+    Wait Until Page Contains Element  ${xpath_led_button}
+
+    # Now turn off the LED via GUI.
+    Click Element At Coordinates  ${xpath_led_button}  0  0
+
+    # Cross check that server LED off state via Redfish.
+    ${led_status}=  Redfish.Get Attribute  /redfish/v1/Systems/system  IndicatorLED
+    Should Be True  '${led_status}' == 'Off'
+
+
 *** Keywords ***
 
 Test Setup Execution