Fix software representation. Add software tests.

This commit is contained in:
Andris Raugulis committed 2016-10-05 03:27:43 +03:00
1 parent 489a24c564
commit aee949a717
2 files changed
+287 -2

No files matched your search

+2 -2
View File
@@ -567,7 +567,7 @@ class SSH(object):
return self.display()
def __repr__(self):
out = 'vendor={0} '.format(self.vendor) if self.vendor else ''
out = 'vendor={0}'.format(self.vendor) if self.vendor else ''
if self.product:
if self.vendor:
out += ', '
@@ -582,7 +582,7 @@ class SSH(object):
@staticmethod
def _fix_patch(patch):
return re.sub(r'^[-_\.]+', '', patch)
return re.sub(r'^[-_\.]+', '', patch) or None
@staticmethod
def _fix_date(d):