mailr15203 - /branches/spec_api/test_suite/unit_tests/value_testing_base.py


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

Header


Content

Posted by edward on January 20, 2012 - 13:42:
Author: bugman
Date: Fri Jan 20 13:42:50 2012
New Revision: 15203

URL: http://svn.gna.org/viewcvs/relax?rev=15203&view=rev
Log:
Fixes for all of the value.set user function back end unit tests.

The parameter names are now regularised.


Modified:
    branches/spec_api/test_suite/unit_tests/value_testing_base.py

Modified: branches/spec_api/test_suite/unit_tests/value_testing_base.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/spec_api/test_suite/unit_tests/value_testing_base.py?rev=15203&r1=15202&r2=15203&view=diff
==============================================================================
--- branches/spec_api/test_suite/unit_tests/value_testing_base.py (original)
+++ branches/spec_api/test_suite/unit_tests/value_testing_base.py Fri Jan 20 
13:42:50 2012
@@ -163,7 +163,7 @@
         pipes.switch('ct')
 
         # Set the parameter.
-        self.value_fns.set(param='Bond_length', val=1.04e-10)
+        self.value_fns.set(param='r', val=1.04e-10)
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].r, 1.04e-10)
@@ -197,7 +197,7 @@
         pipes.switch('ct')
 
         # Set the parameter.
-        self.value_fns.set(param='heteronucleus', val='13C')
+        self.value_fns.set(param='heteronuc_type', val='13C')
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].heteronuc_type, '13C')
@@ -329,7 +329,7 @@
         pipes.switch('ct')
 
         # Set the parameter.
-        self.value_fns.set(param='bond-Length')
+        self.value_fns.set(param='r')
 
         # Test the parameter.
         self.assertAlmostEqual(cdp.mol[0].res[0].spin[0].r, 1.02e-10)
@@ -363,7 +363,7 @@
         pipes.switch('ct')
 
         # Set the parameter.
-        self.value_fns.set(param='heteronucleus')
+        self.value_fns.set(param='heteronuc_type')
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].heteronuc_type, '15N')
@@ -478,7 +478,7 @@
         pipes.switch('ct')
 
         # Set the parameter.
-        self.value_fns.set(param='Bond_length', val=1.04e-10, spin_id='@112')
+        self.value_fns.set(param='r', val=1.04e-10, spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 'r'))
@@ -512,7 +512,7 @@
         pipes.switch('ct')
 
         # Set the parameter.
-        self.value_fns.set(param='heteronucleus', val='13C', spin_id='@112')
+        self.value_fns.set(param='heteronuc_type', val='13C', spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 
'heteronuc_type'))
@@ -2634,7 +2634,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param='J(wH)', val=1.7e-12)
+        self.value_fns.set(param='jwh', val=1.7e-12)
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].jwh, 1.7e-12)
@@ -2651,7 +2651,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param='Bond_length', val=1.04e-10)
+        self.value_fns.set(param='r', val=1.04e-10)
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].r, 1.04e-10)
@@ -2685,7 +2685,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param='heteronucleus', val='13C')
+        self.value_fns.set(param='heteronuc_type', val='13C')
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].heteronuc_type, '13C')
@@ -2702,7 +2702,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param=['J(0)', 'jwx', 'J(wH)'], val=[6.4e-9, 
3.5e-10, 2.3e-12])
+        self.value_fns.set(param=['j0', 'jwx', 'jwh'], val=[6.4e-9, 3.5e-10, 
2.3e-12])
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].j0, 6.4e-9)
@@ -2723,7 +2723,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param=['J(0)', 'jwx', 'J(wH)'], val=1.9e-10)
+        self.value_fns.set(param=['j0', 'jwx', 'jwh'], val=1.9e-10)
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].j0, 1.9e-10)
@@ -2770,7 +2770,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.assertRaises(RelaxParamSetError, self.value_fns.set, 
param='J(wH)')
+        self.assertRaises(RelaxParamSetError, self.value_fns.set, 
param='jwh')
 
 
     def test_set_jw_defaults_r(self):
@@ -2783,7 +2783,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param='bond-Length')
+        self.value_fns.set(param='r')
 
         # Test the parameter.
         self.assertAlmostEqual(cdp.mol[0].res[0].spin[0].r, 1.02e-10)
@@ -2817,7 +2817,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param='heteronucleus')
+        self.value_fns.set(param='heteronuc_type')
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].heteronuc_type, '15N')
@@ -2834,7 +2834,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.assertRaises(RelaxParamSetError, self.value_fns.set, 
param=['J(0)', 'jwx', 'J(wH)'])
+        self.assertRaises(RelaxParamSetError, self.value_fns.set, 
param=['j0', 'jwx', 'jwh'])
 
 
     def test_set_jw_single_spin_j0(self):
@@ -2881,7 +2881,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param='J(wH)', val=1.7e-12, spin_id='@112')
+        self.value_fns.set(param='jwh', val=1.7e-12, spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 'jwh'))
@@ -2898,7 +2898,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param='Bond_length', val=1.04e-10, spin_id='@112')
+        self.value_fns.set(param='r', val=1.04e-10, spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 'r'))
@@ -2932,7 +2932,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param='heteronucleus', val='13C', spin_id='@112')
+        self.value_fns.set(param='heteronuc_type', val='13C', spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 
'heteronuc_type'))
@@ -2949,7 +2949,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param=['J(0)', 'jwx', 'J(wH)'], val=[6.4e-9, 
3.5e-10, 2.3e-12], spin_id='@112')
+        self.value_fns.set(param=['j0', 'jwx', 'jwh'], val=[6.4e-9, 3.5e-10, 
2.3e-12], spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 'j0'))
@@ -2970,7 +2970,7 @@
         pipes.switch('jw')
 
         # Set the parameter.
-        self.value_fns.set(param=['J(0)', 'jwx', 'J(wH)'], val=1.9e-10, 
spin_id='@112')
+        self.value_fns.set(param=['j0', 'jwx', 'jwh'], val=1.9e-10, 
spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 'j0'))
@@ -2997,7 +2997,7 @@
         pipes.switch('mf')
 
         # Set the parameter.
-        self.value_fns.set(param='local tm', val=1e-8)
+        self.value_fns.set(param='local_tm', val=1e-8)
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].local_tm, 1e-8)
@@ -3133,7 +3133,7 @@
         pipes.switch('mf')
 
         # Set the parameter.
-        self.value_fns.set(param='Bond length', val=1.02e-10)
+        self.value_fns.set(param='r', val=1.02e-10)
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].r, 1.02e-10)
@@ -3167,7 +3167,7 @@
         pipes.switch('mf')
 
         # Set the parameter.
-        self.value_fns.set(param='heteronucleus', val='13C')
+        self.value_fns.set(param='heteronuc_type', val='13C')
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].heteronuc_type, '13C')
@@ -3222,7 +3222,7 @@
         pipes.switch('mf')
 
         # Set the parameter.
-        self.value_fns.set(param='local tm')
+        self.value_fns.set(param='local_tm')
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].local_tm, 10 * 1e-9)
@@ -3358,7 +3358,7 @@
         pipes.switch('mf')
 
         # Set the parameter.
-        self.value_fns.set(param='Bond length')
+        self.value_fns.set(param='r')
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].r, 1.02 * 1e-10)
@@ -3392,7 +3392,7 @@
         pipes.switch('mf')
 
         # Set the parameter.
-        self.value_fns.set(param='heteronucleus')
+        self.value_fns.set(param='heteronuc_type')
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].heteronuc_type, '15N')
@@ -3428,7 +3428,7 @@
         pipes.switch('mf')
 
         # Set the parameter.
-        self.value_fns.set(param='local tm', val=1e-8, spin_id='@112')
+        self.value_fns.set(param='local_tm', val=1e-8, spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 'local_tm'))
@@ -3564,7 +3564,7 @@
         pipes.switch('mf')
 
         # Set the parameter.
-        self.value_fns.set(param='Bond length', val=1.02e-10, spin_id='@112')
+        self.value_fns.set(param='r', val=1.02e-10, spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 'r'))
@@ -3598,7 +3598,7 @@
         pipes.switch('mf')
 
         # Set the parameter.
-        self.value_fns.set(param='heteronucleus', val='13C', spin_id='@112')
+        self.value_fns.set(param='heteronuc_type', val='13C', spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 
'heteronuc_type'))
@@ -3718,7 +3718,7 @@
         pipes.switch('relax_fit')
 
         # Set the parameter.
-        self.value_fns.set(param='Iinf', val=-1.7)
+        self.value_fns.set(param='iinf', val=-1.7)
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].iinf, -1.7)
@@ -3735,7 +3735,7 @@
         pipes.switch('relax_fit')
 
         # Set the parameter.
-        self.value_fns.set(param=['I0', 'iinf'], val=[123456, -1.7])
+        self.value_fns.set(param=['i0', 'iinf'], val=[123456, -1.7])
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].i0, 123456)
@@ -3754,7 +3754,7 @@
         pipes.switch('relax_fit')
 
         # Set the parameter.
-        self.value_fns.set(param=['I0', 'iinf'], val=0.0)
+        self.value_fns.set(param=['i0', 'iinf'], val=0.0)
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].i0, 0.0)
@@ -3807,7 +3807,7 @@
         pipes.switch('relax_fit')
 
         # Set the parameter.
-        self.value_fns.set(param='Iinf')
+        self.value_fns.set(param='iinf')
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].iinf, 0.0)
@@ -3824,7 +3824,7 @@
         pipes.switch('relax_fit')
 
         # Set the parameter.
-        self.value_fns.set(param=['I0', 'iinf'])
+        self.value_fns.set(param=['i0', 'iinf'])
 
         # Test the parameter.
         self.assertEqual(cdp.mol[0].res[0].spin[0].i0, 10000.0)
@@ -3877,7 +3877,7 @@
         pipes.switch('relax_fit')
 
         # Set the parameter.
-        self.value_fns.set(param='Iinf', val=-1.7, spin_id='@112')
+        self.value_fns.set(param='iinf', val=-1.7, spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 'iinf'))
@@ -3894,7 +3894,7 @@
         pipes.switch('relax_fit')
 
         # Set the parameter.
-        self.value_fns.set(param=['I0', 'iinf'], val=[123456, -1.7], 
spin_id='@112')
+        self.value_fns.set(param=['i0', 'iinf'], val=[123456, -1.7], 
spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 'i0'))
@@ -3913,7 +3913,7 @@
         pipes.switch('relax_fit')
 
         # Set the parameter.
-        self.value_fns.set(param=['I0', 'iinf'], val=0.0, spin_id='@112')
+        self.value_fns.set(param=['i0', 'iinf'], val=0.0, spin_id='@112')
 
         # Test the parameter.
         self.assert_(not hasattr(cdp.mol[0].res[0].spin[0], 'i0'))




Related Messages


Powered by MHonArc, Updated Fri Jan 20 14:40:02 2012