Trees | Indices | Help |
|
---|
|
1 ############################################################################### 2 # # 3 # Copyright (C) 2014 Troels E. Linnet # 4 # # 5 # This file is part of the program relax (http://www.nmr-relax.com). # 6 # # 7 # This program is free software: you can redistribute it and/or modify # 8 # it under the terms of the GNU General Public License as published by # 9 # the Free Software Foundation, either version 3 of the License, or # 10 # (at your option) any later version. # 11 # # 12 # This program is distributed in the hope that it will be useful, # 13 # but WITHOUT ANY WARRANTY; without even the implied warranty of # 14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # 15 # GNU General Public License for more details. # 16 # # 17 # You should have received a copy of the GNU General Public License # 18 # along with this program. If not, see <http://www.gnu.org/licenses/>. # 19 # # 20 ############################################################################### 21 22 # Python module imports. 23 from copy import deepcopy 24 25 # relax module imports. 26 from lib.dispersion.variables import MODEL_CR72, MODEL_MMQ_CR72, MODEL_NS_CPMG_2SITE_EXPANDED, MODEL_NS_R1RHO_3SITE 27 from lib.dispersion.variables import MODEL_EXP_TYPE, MODEL_EQ, MODEL_PARAMS, MODEL_SITES, MODEL_YEAR 28 from test_suite.unit_tests.base_classes import UnitTestCase 29 3032 """Unit tests for the functions of the lib.dispersion.variables module.""" 33 348336 """Unit test of the MODEL_PARAM dictionary.""" 37 38 # Test parameter return from model parameter dictionary. 39 params_cr72 = deepcopy(MODEL_PARAMS[MODEL_CR72]) 40 41 # Test the return. 42 self.assertEqual(params_cr72, ['r2', 'pA', 'dw', 'kex'])43 4446 """Unit test of the MODEL_YEAR dictionary.""" 47 48 # Test model year return from model year dictionary. 49 year_cr72 = MODEL_YEAR[MODEL_CR72] 50 51 # Test the return. 52 self.assertEqual(year_cr72, 1972)53 5456 """Unit test of the MODEL_EXP_TYPE dictionary.""" 57 58 # Test model year return from model year dictionary. 59 exp_type_mmq_cr72 = MODEL_EXP_TYPE[MODEL_MMQ_CR72] 60 61 # Test the return. 62 self.assertEqual(exp_type_mmq_cr72, 'CPMG: SQ, DQ, MQ, ZQ, 1H SQ, 1H MQ')63 6466 """Unit test of the MODEL_SITES dictionary.""" 67 68 # Test model chemical sites return from model sites dictionary. 69 model_sites = MODEL_SITES[MODEL_NS_R1RHO_3SITE] 70 71 # Test the return. 72 self.assertEqual(model_sites, 3)73 7476 """Unit test of the MODEL_EQ dictionary.""" 77 78 # Test model equation type return from model equation dictionary. 79 model_eq = MODEL_EQ[MODEL_NS_CPMG_2SITE_EXPANDED] 80 81 # Test the return. 82 self.assertEqual(model_eq, 'silico')
Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Sat Jun 8 10:44:57 2024 | http://epydoc.sourceforge.net |