Moved channel test cases in new IPMI bucket

Change-Id: I4e5a560a8a4f5b2b99f13d2768d9da730b492152
Signed-off-by: Rahul Maheshwari <rahulmaheshwari@in.ibm.com>
diff --git a/ipmi/test_ipmi_network.robot b/ipmi/test_ipmi_network.robot
index 62719dc..f7ccdbc 100644
--- a/ipmi/test_ipmi_network.robot
+++ b/ipmi/test_ipmi_network.robot
@@ -3,6 +3,7 @@
 Documentation          Module to test IPMI network functionality.
 Resource               ../lib/ipmi_client.robot
 Resource               ../lib/openbmc_ffdc.robot
+Resource               ../lib/bmc_network_utils.robot
 Library                ../lib/ipmi_utils.py
 Library                ../lib/gen_robot_valid.py
 
@@ -65,6 +66,37 @@
     Valid Value  lan_print_ipmi['MAC Address']  ${mac_address_redfish}
 
 
+Test Valid IPMI Channels Supported
+    [Documentation]  Verify IPMI channels supported on a given system.
+    [Tags]  Test_Valid_IPMI_Channels_Supported
+
+    ${channel_count}=  Get Physical Network Interface Count
+
+    # Note: IPMI network channel logically starts from 1.
+    :FOR  ${channel_number}  IN RANGE  1  ${channel_count}
+    \  Run IPMI Standard Command  lan print ${channel_number}
+
+
+Test Invalid IPMI Channel Response
+    [Documentation]  Verify invalid IPMI channels supported response.
+    [Tags]  Test_Invalid_IPMI_Channel_Response
+
+    ${channel_count}=  Get Physical Network Interface Count
+
+    # To target invalid channel, increment count.
+    ${channel_number}=  Evaluate  ${channel_count} + 1
+
+    # Example of invalid channel:
+    # $ ipmitool -I lanplus -H xx.xx.xx.xx -P password lan print 3
+    # Get Channel Info command failed: Parameter out of range
+    # Invalid channel: 3
+
+    ${stdout}=  Run External IPMI Standard Command
+    ...  lan print ${channel_number}  fail_on_err=${0}
+    Should Contain  ${stdout}  Invalid channel
+    ...  msg=IPMI channel ${channel_number} is invalid but seen working.
+
+
 Verify IPMI Inband Network Configuration
     [Documentation]  Verify BMC network configuration via inband IPMI.
     [Tags]  Verify_IPMI_Inband_Network_Configuration
@@ -85,6 +117,19 @@
 
 *** Keywords ***
 
+Get Physical Network Interface Count
+    [Documentation]  Return valid physical network interfaces count.
+    # Example:
+    # link/ether 22:3a:7f:70:92:cb brd ff:ff:ff:ff:ff:ff
+    # link/ether 0e:8e:0d:6b:e9:e4 brd ff:ff:ff:ff:ff:ff
+
+    ${mac_entry_list}=  Get BMC MAC Address List
+    ${mac_unique_list}=  Remove Duplicates  ${mac_entry_list}
+    ${physical_interface_count}=  Get Length  ${mac_unique_list}
+
+    [Return]  ${physical_interface_count}
+
+
 Set IPMI Inband Network Configuration
     [Documentation]  Run sequence of standard IPMI command in-band and set
     ...              the IP configuration.
diff --git a/tests/ipmi/test_general_ipmi.robot b/tests/ipmi/test_general_ipmi.robot
index e44181a..9ce0e4c 100755
--- a/tests/ipmi/test_general_ipmi.robot
+++ b/tests/ipmi/test_general_ipmi.robot
@@ -345,37 +345,6 @@
     ...  msg=BMC aux version ${bmc_aux_version} does not match expected value of ${aux_version}.
 
 
-Test Valid IPMI Channels Supported
-    [Documentation]  Verify IPMI channels supported on a given system.
-    [Tags]  Test_Valid_IPMI_Channels_Supported
-
-    ${channel_count}=  Get Physical Network Interface Count
-
-    # Note: IPMI network channel logically starts from 1.
-    :FOR  ${channel_number}  IN RANGE  1  ${channel_count}
-    \  Run IPMI Standard Command  lan print ${channel_number}
-
-
-Test Invalid IPMI Channel Response
-    [Documentation]  Verify invalid IPMI channels supported response.
-    [Tags]  Test_Invalid_IPMI_Channel_Response
-
-    ${channel_count}=  Get Physical Network Interface Count
-
-    # To target invalid channel, increment count.
-    ${channel_number}=  Evaluate  ${channel_count} + 1
-
-    # Example of invalid channel:
-    # $ ipmitool -I lanplus -H xx.xx.xx.xx -P password lan print 3
-    # Get Channel Info command failed: Parameter out of range
-    # Invalid channel: 3
-
-    ${stdout}=  Run External IPMI Standard Command
-    ...  lan print ${channel_number}  fail_on_err=${0}
-    Should Contain  ${stdout}  Invalid channel
-    ...  msg=IPMI channel ${channel_number} is invalid but seen working.
-
-
 Test IPMI Restriction Mode
     [Documentation]  Set restricition mode via REST and verify IPMI operation.
     [Tags]  Test_IPMI_Restriction_Mode
@@ -538,20 +507,6 @@
     ...  msg=Power reading above allowed threshold ${allowed_power_diff}.
 
 
-Get Physical Network Interface Count
-    [Documentation]  Return valid physical network interfaces count.
-
-    # Example:
-    # link/ether 22:3a:7f:70:92:cb brd ff:ff:ff:ff:ff:ff
-    # link/ether 0e:8e:0d:6b:e9:e4 brd ff:ff:ff:ff:ff:ff
-
-    ${mac_entry_list}=  Get BMC MAC Address List
-    ${mac_unique_list}=  Remove Duplicates  ${mac_entry_list}
-    ${physical_interface_count}=  Get Length  ${mac_unique_list}
-
-    [Return]  ${physical_interface_count}
-
-
 Set IPMI Restriction Mode
     [Documentation]  Set the IPMI restriction mode.
     [Arguments]  ${restriction_mode}