Modified keyword 'Get Network Configuration'
Let user to specify Ethernet Interface name by channel number while
running, if not, the channel number default is 1.
Signed-off-by: Tony Lee <tony.lee@quantatw.com>
Change-Id: I02131688a6c7bf3c383dfa51ee97fe7501b04b42
diff --git a/lib/bmc_network_utils.robot b/lib/bmc_network_utils.robot
index b4c6c79..15d80ce 100644
--- a/lib/bmc_network_utils.robot
+++ b/lib/bmc_network_utils.robot
@@ -4,6 +4,7 @@
Resource ../lib/boot_utils.robot
Library ../lib/gen_misc.py
Library ../lib/utils.py
+Library ../lib/bmc_network_utils.py
*** Variables ***
# MAC input from user.
@@ -352,8 +353,8 @@
# "VLANEnable": false,
# "VLANId": 0
# }
-
- ${resp}= Redfish.Get ${REDFISH_NW_ETH0_URI}
+ ${active_channel_config}= Get Active Channel Config
+ ${resp}= Redfish.Get ${REDFISH_NW_ETH_IFACE}/${active_channel_config['${CHANNEL_NUMBER}']['name']}
@{network_configurations}= Get From Dictionary ${resp.dict} IPv4StaticAddresses
[Return] @{network_configurations}