Author: bugman Date: Fri Feb 15 09:45:03 2008 New Revision: 4996 URL: http://svn.gna.org/viewcvs/relax?rev=4996&view=rev Log: Fixed the pivot_point arg test of the n_state_model.CoM() user function. This was using the now non-existant n_state_model.pivot_point() user function. Modified: branches/N_state_model/test_suite/unit_tests/_prompt/test_n_state_model.py Modified: branches/N_state_model/test_suite/unit_tests/_prompt/test_n_state_model.py URL: http://svn.gna.org/viewcvs/relax/branches/N_state_model/test_suite/unit_tests/_prompt/test_n_state_model.py?rev=4996&r1=4995&r2=4996&view=diff ============================================================================== --- branches/N_state_model/test_suite/unit_tests/_prompt/test_n_state_model.py (original) +++ branches/N_state_model/test_suite/unit_tests/_prompt/test_n_state_model.py Fri Feb 15 09:45:03 2008 @@ -38,6 +38,34 @@ # Instantiate the user function class. n_state_model_fns = N_state_model(fake_relax.fake_instance()) + + + def test_CoM_argfail_pivot_point(self): + """The pivot_point arg test of the n_state_model.CoM() user function.""" + + # Loop over the data types. + for data in DATA_TYPES: + # Catch the None arguments, and skip them. + if data[0] == 'None': + continue + + # Catch the list arguments. + if type(data[1]) == list: + # The wrong length. + if len(data[1]) != 3: + self.assertRaises(RelaxLenError, self.n_state_model_fns.CoM, pivot_point=data[1]) + + # Catch the int, float, and number list arguments, and skip them. + elif data[0] == 'int list' or data[0] == 'float list' or data[0] == 'number list': + continue + + # The argument test. + else: + self.assertRaises(RelaxListNumError, self.n_state_model_fns.CoM, pivot_point=data[1]) + + # All other arguments. + else: + self.assertRaises(RelaxListError, self.n_state_model_fns.CoM, pivot_point=data[1]) def test_CoM_argfail_centre(self): @@ -94,34 +122,6 @@ self.assertRaises(RelaxStrError, self.n_state_model_fns.model, N=5, ref=data[1]) - def test_pivot_point_argfail_pivot(self): - """The pivot arg test of the n_state_model.pivot_point() user function.""" - - # Loop over the data types. - for data in DATA_TYPES: - # Catch the None arguments, and skip them. - if data[0] == 'None': - continue - - # Catch the list arguments. - if type(data[1]) == list: - # The wrong length. - if len(data[1]) != 3: - self.assertRaises(RelaxLenError, self.n_state_model_fns.pivot_point, pivot=data[1]) - - # Catch the int, float, and number list arguments, and skip them. - elif data[0] == 'int list' or data[0] == 'float list' or data[0] == 'number list': - continue - - # The argument test. - else: - self.assertRaises(RelaxListNumError, self.n_state_model_fns.pivot_point, pivot=data[1]) - - # All other arguments. - else: - self.assertRaises(RelaxListError, self.n_state_model_fns.pivot_point, pivot=data[1]) - - def test_set_domain_argfail_tensor(self): """Failure of the tensor arg of the n_state_model.set_domain() user function."""