selftest/trial_test: Fix repr(RuntimeError) changing in new python version

If using python 3.8.2, the trailing comma at the end of parameters is
not longer there (probably got fixed, since it's not needed). That
change breaks expected output.

Change-Id: I6da3024f946c0e761099058e812c0eacf3d6071f
diff --git a/selftest/resource_test.ok b/selftest/resource_test.ok
index 08989a2..6147408 100644
--- a/selftest/resource_test.ok
+++ b/selftest/resource_test.ok
@@ -6,7 +6,7 @@
 - expect failure to solve:
 The requested resource requirements are not solvable [[0, 2], [2], [0, 2]]
 - test removing a Resources list from itself
-ok, caused exception: RuntimeError('Refusing to drop a list of resources from itself. This is probably a bug where a list of Resources() should have been copied but is passed as-is. use Resources.clear() instead.',)
+ok, caused exception RuntimeError: Refusing to drop a list of resources from itself. This is probably a bug where a list of Resources() should have been copied but is passed as-is. use Resources.clear() instead.
 - test removing a Resources list from one with the same list in it
 - test resources config and state dir:
 cnf -: DBG: Found config file paths.conf as [PATH]/selftest/conf/paths.conf in ./conf which is [PATH]/selftest/conf
diff --git a/selftest/resource_test.py b/selftest/resource_test.py
index 0b9550e..3f7cd51 100755
--- a/selftest/resource_test.py
+++ b/selftest/resource_test.py
@@ -53,7 +53,7 @@
     r.drop(r)
     assert False
 except RuntimeError as e:
-    print('ok, caused exception: %r' % e)
+    print('ok, caused exception RuntimeError: %s' % str(e))
 
 print('- test removing a Resources list from one with the same list in it')
 r = resource.Resources({ 'k': [ {'a': 1, 'b': 2}, {'a': 3, 'b': 4}, ],
diff --git a/selftest/trial_test.ok b/selftest/trial_test.ok
index 6ad39a9..8c6a567 100644
--- a/selftest/trial_test.ok
+++ b/selftest/trial_test.ok
@@ -11,6 +11,6 @@
 None
 - test checksum verification
 - detect wrong checksum
-ok, got RuntimeError("Checksum mismatch for '[PATH]/trial_test/invalid_checksum/file2' vs. '[PATH]/trial_test/invalid_checksum/checksums.md5' line 2",)
+ok, got RuntimeError: Checksum mismatch for '[PATH]/trial_test/invalid_checksum/file2' vs. '[PATH]/trial_test/invalid_checksum/checksums.md5' line 2
 - detect missing file
-ok, got RuntimeError("File listed in checksums file but missing in trials dir: '[PATH]/trial_test/missing_file/file2' vs. '[PATH]/trial_test/missing_file/checksums.md5' line 2",)
+ok, got RuntimeError: File listed in checksums file but missing in trials dir: '[PATH]/trial_test/missing_file/file2' vs. '[PATH]/trial_test/missing_file/checksums.md5' line 2
diff --git a/selftest/trial_test.py b/selftest/trial_test.py
index 41d71e6..a99428a 100755
--- a/selftest/trial_test.py
+++ b/selftest/trial_test.py
@@ -37,13 +37,13 @@
 try:
     t.verify()
 except RuntimeError as e:
-    print('ok, got %r' % e)
+    print('ok, got RuntimeError: %s' % str(e))
 
 print('- detect missing file')
 t = Trial(d.child('missing_file'))
 try:
     t.verify()
 except RuntimeError as e:
-    print('ok, got %r' % e)
+    print('ok, got RuntimeError: %s' % str(e))
 
 # vim: expandtab tabstop=4 shiftwidth=4