From 25aee9dd1f487176499994c5c540da18dee63c33 Mon Sep 17 00:00:00 2001
From: Gabriel Studer <gabriel.studer@unibas.ch>
Date: Thu, 28 Nov 2019 14:18:14 +0100
Subject: [PATCH] Relax QSscorer unit test for highly symmetric structures

Several chain mappings are valid in this case. Only check whether we found an
automated mapping with strict (stuff must really match) chain_mapping_scheme
---
 modules/mol/alg/tests/test_qsscoring.py | 18 ++++++++++++------
 1 file changed, 12 insertions(+), 6 deletions(-)

diff --git a/modules/mol/alg/tests/test_qsscoring.py b/modules/mol/alg/tests/test_qsscoring.py
index 0e57f2a3e..e8f18b369 100644
--- a/modules/mol/alg/tests/test_qsscoring.py
+++ b/modules/mol/alg/tests/test_qsscoring.py
@@ -547,12 +547,18 @@ class TestQSscore(unittest.TestCase):
     self.assertEqual(len(qs_scorer.symm_1[0]), 2)
     self.assertEqual(len(qs_scorer.symm_2), 12)
     self.assertEqual(len(qs_scorer.symm_2[0]), 2)
-    self.assertEqual(qs_scorer.chain_mapping,
-                     {'A': 'J', 'C': 'L', 'B': 'K', 'E': 'P', 'D': 'R',
-                      'G': 'O', 'F': 'Q', 'I': 'T', 'H': 'X', 'K': 'S',
-                      'J': 'U', 'M': 'G', 'L': 'I', 'O': 'N', 'N': 'H',
-                      'Q': 'E', 'P': 'V', 'S': 'D', 'R': 'F', 'U': 'B',
-                      'T': 'A', 'W': 'M', 'V': 'C', 'X': 'W'})
+
+    # Don't check for exact mapping, as structures are highly symmetric.
+    # Several mappings are thus valid. Only check whether we found an
+    # automated mapping with strict (stuff must really match)
+    # chain_mapping_scheme
+    self.assertEqual(qs_scorer.chain_mapping_scheme, 'strict')
+    #self.assertEqual(qs_scorer.chain_mapping,
+    #                 {'A': 'J', 'C': 'L', 'B': 'K', 'E': 'P', 'D': 'R',
+    #                  'G': 'O', 'F': 'Q', 'I': 'T', 'H': 'X', 'K': 'S',
+    #                  'J': 'U', 'M': 'G', 'L': 'I', 'O': 'N', 'N': 'H',
+    #                  'Q': 'E', 'P': 'V', 'S': 'D', 'R': 'F', 'U': 'B',
+    #                  'T': 'A', 'W': 'M', 'V': 'C', 'X': 'W'})
 
 
   ###########################################################################
-- 
GitLab