[diffoscope] 05/05: tests.comparators.utils: Add a get_data helper method
Chris Lamb
chris at chris-lamb.co.uk
Thu Feb 2 03:51:25 CET 2017
This is an automated email from the git hooks/post-receive script.
lamby pushed a commit to branch master
in repository diffoscope.
commit 19a189091b57eed5621144dd83239d804fffe119
Author: Chris Lamb <lamby at debian.org>
Date: Thu Feb 2 15:00:48 2017 +1300
tests.comparators.utils: Add a get_data helper method
Signed-off-by: Chris Lamb <lamby at debian.org>
---
tests/comparators/utils/data.py | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/tests/comparators/utils/data.py b/tests/comparators/utils/data.py
index e2da749..c1d2c2c 100644
--- a/tests/comparators/utils/data.py
+++ b/tests/comparators/utils/data.py
@@ -40,5 +40,10 @@ def data(filename):
)
+def get_data(filename):
+ with open(data(filename), encoding='utf-8') as f:
+ return f.read()
+
+
def load_fixture(filename):
return init_fixture(data(filename))
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/diffoscope.git
More information about the diffoscope
mailing list