Clean up exception handling in TestON core
- Catch more specific exceptions
- Clearer Style
- Allow CTRL-C to exit the test cleanly whether from the TestON
cli or ruinning as a script
Change-Id: I5c7d39b334c57e3e0162eef00f82a797a78144fd
diff --git a/TestON/core/xmlparser.py b/TestON/core/xmlparser.py
index e2cfb1d..f12f69c 100644
--- a/TestON/core/xmlparser.py
+++ b/TestON/core/xmlparser.py
@@ -39,7 +39,7 @@
try :
parsedInfo = xmldict.xml_to_dict(xml)
return parsedInfo
- except Exception as e:
+ except StandardError as e:
print "Error parsing file " + fileName + ": " + e.message
else :
print "File name is not correct"