summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Waldmann <tw@waldmann-edv.de>2022-09-10 19:05:29 +0200
committerThomas Waldmann <tw@waldmann-edv.de>2022-09-10 22:06:34 +0200
commit208475f707aaac7b6051532aeede25c5c759a77f (patch)
tree98ba2c3b111cd4afa3a6be2e01031ba37c34efcf
parentc27df634f1cec374a99af5477d6fc867b99c09d4 (diff)
xattrs: adapt tests to new error msgs2.0.0b2
-rw-r--r--src/borg/testsuite/archiver.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/borg/testsuite/archiver.py b/src/borg/testsuite/archiver.py
index 066bbe72c..fa35f9a26 100644
--- a/src/borg/testsuite/archiver.py
+++ b/src/borg/testsuite/archiver.py
@@ -1590,17 +1590,18 @@ class ArchiverTestCase(ArchiverTestCaseBase):
input_abspath = os.path.abspath("input/file")
with patch.object(xattr, "setxattr", patched_setxattr_E2BIG):
out = self.cmd(f"--repo={self.repository_location}", "extract", "test", exit_code=EXIT_WARNING)
- assert ": when setting extended attribute user.attribute: too big for this filesystem\n" in out
+ assert "too big for this filesystem" in out
+ assert "when setting extended attribute user.attribute" in out
os.remove(input_abspath)
with patch.object(xattr, "setxattr", patched_setxattr_ENOTSUP):
out = self.cmd(f"--repo={self.repository_location}", "extract", "test", exit_code=EXIT_WARNING)
- assert (
- ": when setting extended attribute user.attribute: xattrs not supported on this filesystem\n" in out
- )
+ assert "ENOTSUP" in out
+ assert "when setting extended attribute user.attribute" in out
os.remove(input_abspath)
with patch.object(xattr, "setxattr", patched_setxattr_EACCES):
out = self.cmd(f"--repo={self.repository_location}", "extract", "test", exit_code=EXIT_WARNING)
- assert ": when setting extended attribute user.attribute: Permission denied\n" in out
+ assert "EACCES" in out
+ assert "when setting extended attribute user.attribute" in out
assert os.path.isfile(input_abspath)
def test_path_normalization(self):