From 68cf375a9c5b814d997351fa6302dd16d19967cf Mon Sep 17 00:00:00 2001
From: Gabriel Studer <gabriel.studer@unibas.ch>
Date: Fri, 24 May 2024 13:10:42 +0200
Subject: [PATCH] ligand scoring: avoid weird effects on cached parameter in
 unit tests

---
 modules/mol/alg/tests/test_ligand_scoring.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/modules/mol/alg/tests/test_ligand_scoring.py b/modules/mol/alg/tests/test_ligand_scoring.py
index c60c7cba1..1bd7971c9 100644
--- a/modules/mol/alg/tests/test_ligand_scoring.py
+++ b/modules/mol/alg/tests/test_ligand_scoring.py
@@ -739,6 +739,7 @@ class TestLigandScoring(unittest.TestCase):
 
         sc = LigandScorer(mdl, trg, target_ligands=[trg_zn, trg_g3d],
                           coverage_delta=0, substructure_match=True)
+
         self.assertTrue(np.isnan(sc.rmsd_matrix[0, 3]))
         self.assertEqual(sc.unassigned_target_ligands["H"][1], "binding_site")
 
@@ -793,7 +794,7 @@ class TestLigandScoring(unittest.TestCase):
     def test_added_mdl_contacts(self):
 
         # binding site for ligand in chain G consists of chains A and B
-        prot = _LoadMMCIF("1r8q.cif.gz")
+        prot = _LoadMMCIF("1r8q.cif.gz").Copy()
 
         # model has the full binding site
         mdl = mol.CreateEntityFromView(prot.Select("cname=A,B,G"), True)
-- 
GitLab