summaryrefslogtreecommitdiff
path: root/tests/test_process.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_process.py')
-rw-r--r--tests/test_process.py13
1 files changed, 12 insertions, 1 deletions
diff --git a/tests/test_process.py b/tests/test_process.py
index 7c705739..49919b0f 100644
--- a/tests/test_process.py
+++ b/tests/test_process.py
@@ -127,8 +127,13 @@ class ProcessTest(CoverageTest):
self.assert_exists(".coverage")
self.assert_exists(".coverage.bad")
warning_regex = (
+ r"(" # JSON message:
r"Coverage.py warning: Couldn't read data from '.*\.coverage\.bad': "
r"CoverageException: Doesn't seem to be a coverage\.py data file"
+ r"|" # SQL message:
+ r"Coverage.py warning: Couldn't use data file '.*\.coverage\.bad': "
+ r"file is encrypted or is not a database"
+ r")"
)
self.assertRegex(out, warning_regex)
@@ -160,8 +165,14 @@ class ProcessTest(CoverageTest):
for n in "12":
self.assert_exists(".coverage.bad{0}".format(n))
warning_regex = (
+ r"(" # JSON message:
r"Coverage.py warning: Couldn't read data from '.*\.coverage\.bad{0}': "
- r"CoverageException: Doesn't seem to be a coverage\.py data file".format(n)
+ r"CoverageException: Doesn't seem to be a coverage\.py data file"
+ r"|" # SQL message:
+ r"Coverage.py warning: Couldn't use data file '.*\.coverage.bad{0}': "
+ r"file is encrypted or is not a database"
+ r")"
+ .format(n)
)
self.assertRegex(out, warning_regex)
self.assertRegex(out, r"No usable data files")