mailr3836 - /1.3/test_suite/unit_tests/sequence_testing_base.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on November 22, 2007 - 18:31:
Author: bugman
Date: Thu Nov 22 18:31:25 2007
New Revision: 3836

URL: http://svn.gna.org/viewcvs/relax?rev=3836&view=rev
Log:
Bug fix for the unit test for reading of the amino acid sequence out of a 
protein NOE data file.
 
The path has been changed to a relative path so that the unit tests can be 
run by themselves or as
part of relax.


Modified:
    1.3/test_suite/unit_tests/sequence_testing_base.py

Modified: 1.3/test_suite/unit_tests/sequence_testing_base.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/test_suite/unit_tests/sequence_testing_base.py?rev=3836&r1=3835&r2=3836&view=diff
==============================================================================
--- 1.3/test_suite/unit_tests/sequence_testing_base.py (original)
+++ 1.3/test_suite/unit_tests/sequence_testing_base.py Thu Nov 22 18:31:25 
2007
@@ -22,6 +22,7 @@
 
 # Python module imports.
 from os import remove, tempnam
+import sys
 try:
     from hashlib import md5
 except ImportError:
@@ -70,8 +71,13 @@
         The functions tested are generic_fns.sequence.read() and 
prompt.sequence.read().
         """
 
+        # Get the relative path of relax.
+        path = sys.path[0]
+        if path == '.':
+            path = sys.path[-1]
+
         # Read the residue sequence out of the Ap4Aase 600 MHz NOE data file.
-        self.sequence_fns.read(file='Ap4Aase.Noe.600.bz2', 
dir='../shared_data/relaxation_data')
+        self.sequence_fns.read(file='Ap4Aase.Noe.600.bz2', 
dir=path+'/test_suite/shared_data/relaxation_data')
 
         # Test parts of the sequence.
         self.assertEqual(relax_data_store['orig'].mol[0].res[0].num, 1)




Related Messages


Powered by MHonArc, Updated Thu Nov 22 18:40:09 2007