From 0a40676a1ba2e69553a52cdac1faa8a43af57759 Mon Sep 17 00:00:00 2001 From: dave <dave@dtu.dk> Date: Wed, 6 Apr 2016 23:43:50 +0200 Subject: [PATCH] prepost.Simulations: only test txt file, not dict --- wetb/prepost/tests/test_Simulations.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/wetb/prepost/tests/test_Simulations.py b/wetb/prepost/tests/test_Simulations.py index 6c411881..61628546 100644 --- a/wetb/prepost/tests/test_Simulations.py +++ b/wetb/prepost/tests/test_Simulations.py @@ -55,11 +55,14 @@ class TestGenerateInputs(unittest.TestCase): # for the pickled file we can just read it remote = os.path.join(p_root, tmpl.PROJECT, 'remote', 'prepost') ref = os.path.join(p_root, tmpl.PROJECT, 'ref', 'prepost') - with open(os.path.join(remote, 'remote.pkl'), 'rb') as FILE: - pkl_remote = pickle.load(FILE) - with open(os.path.join(ref, 'remote.pkl'), 'rb') as FILE: - pkl_ref = pickle.load(FILE) - self.assertTrue(pkl_remote == pkl_ref) + cmp = filecmp.cmp(os.path.join(remote, 'remote_tags.txt'), + os.path.join(ref, 'remote_tags.txt'), shallow=False) + self.assertTrue(cmp) +# with open(os.path.join(remote, 'remote.pkl'), 'rb') as FILE: +# pkl_remote = pickle.load(FILE) +# with open(os.path.join(ref, 'remote.pkl'), 'rb') as FILE: +# pkl_ref = pickle.load(FILE) +# self.assertTrue(pkl_remote == pkl_ref) if __name__ == "__main__": -- GitLab