Cope with slightly different messages from differing firmware versions
Change-Id: I6080e3d66b7c1cc01811f542ce6fc2ba2bdc0060
diff --git a/drivers/CiscoSX300.py b/drivers/CiscoSX300.py
index 56caecb..083bfcc 100644
--- a/drivers/CiscoSX300.py
+++ b/drivers/CiscoSX300.py
@@ -308,7 +308,7 @@
raise InputError("Port name %s not recognised" % port)
if not (self.port_get_mode(port) == "access"):
raise InputError("Port %s not in access mode" % port)
- regex = re.compile(r'(\d+)\s+\S+\s+Untagged\s+(Static|System)')
+ regex = re.compile(r'(\d+)\s+\S+\s+Untagged\s+(D|S|G|R)')
try:
self._cli("show interfaces switchport %s" % port)
@@ -331,7 +331,7 @@
raise InputError("Port name %s not recognised" % port)
if not (self.port_get_mode(port) == "trunk"):
raise InputError("Port %s not in trunk mode" % port)
- regex = re.compile(r'(\d+)\s+\S+\s+(Tagged|Untagged)\s+Static')
+ regex = re.compile(r'(\d+)\s+\S+\s+(Tagged|Untagged)\s+(D|S|G|R)')
try:
self._cli("show interfaces switchport %s" % port)