From 41cb84a7ccf9a8e4926618230db4e84d630fbbf7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Rapinat?= Date: Sat, 17 May 2014 15:22:24 +0200 Subject: [PATCH] 7648: [Unit test] database dir and environment; https://gramps-project.org/bugs/view.php?id=7648#c36301 ; works on jralls' config, not yet on mine --- gramps/cli/test/cli_test.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/gramps/cli/test/cli_test.py b/gramps/cli/test/cli_test.py index 2f5c408e8..7b61f6b15 100644 --- a/gramps/cli/test/cli_test.py +++ b/gramps/cli/test/cli_test.py @@ -43,6 +43,13 @@ test_ged = """0 HEAD 0 TRLR """ +# see gramps.grampsapp.py +## hack to avoid mentioning 'utf8' encoding everywhere unicode or str is is used +if sys.version_info[0] < 3: + reload(sys) + sys.setdefaultencoding('utf8') +## + ddir = os.path.dirname(__file__) min1r = os.path.join(ddir, "min1r.ged") out_ged = os.path.join(ddir, "test_out.ged")