mailr8132 - /1.3/test_suite/system_tests/relax_fit.py


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

Header


Content

Posted by edward on December 04, 2008 - 16:36:
Author: bugman
Date: Thu Dec  4 16:36:02 2008
New Revision: 8132

URL: http://svn.gna.org/viewcvs/relax?rev=8132&view=rev
Log:
Added code to check the Grace files created by the 1UBQ_relax_fit.py system 
test script.


Modified:
    1.3/test_suite/system_tests/relax_fit.py

Modified: 1.3/test_suite/system_tests/relax_fit.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/test_suite/system_tests/relax_fit.py?rev=8132&r1=8131&r2=8132&view=diff
==============================================================================
--- 1.3/test_suite/system_tests/relax_fit.py (original)
+++ 1.3/test_suite/system_tests/relax_fit.py Thu Dec  4 16:36:02 2008
@@ -21,6 +21,8 @@
 
###############################################################################
 
 # Python module imports.
+from os import sep
+from string import split
 import sys
 from tempfile import mkdtemp
 from unittest import TestCase
@@ -59,6 +61,20 @@
 
         # Execute the script.
         self.relax.interpreter.run(script_file=sys.path[-1] + 
'/test_suite/system_tests/scripts/1UBQ_relax_fit.py')
+
+        # Open the intensities.agr file.
+        file = open(ds.tmpdir + sep + 'intensities.agr')
+        lines = file.readlines()
+        file.close()
+
+        # Split up the lines.
+        for i in xrange(len(lines)):
+            lines[i] = split(lines[i])
+
+        # Check some of the Grace data.
+        self.assertEqual(len(lines[26]), 2)
+        self.assertEqual(lines[26][0], '0.004')
+        self.assertEqual(lines[26][1], '487178.')
 
 
     def test_curve_fitting(self):




Related Messages


Powered by MHonArc, Updated Thu Dec 04 16:40:02 2008