Browse Source

ScriptError: return whatever came in, relates to #3867

Anna Petrasova 5 years ago
parent
commit
42d3493b92

+ 1 - 1
lib/python/exceptions/__init__.py

@@ -45,7 +45,7 @@ class ScriptError(Exception):
         self.value = value
 
     def __str__(self):
-        return str(self.value)
+        return self.value
 
 
 class Usage(Exception):

+ 0 - 2
lib/python/exceptions/testsuite/test_ScriptError.py

@@ -14,8 +14,6 @@ class TestTextAssertions(TestCase):
     def test_str(self):
         error = ScriptError('error')
         self.assertEqual('error', str(error))
-        error = ScriptError(12)
-        self.assertEqual('12', str(error))
 
 
 if __name__ == '__main__':