Author: bugman Date: Mon Jan 7 18:09:07 2008 New Revision: 4449 URL: http://svn.gna.org/viewcvs/relax?rev=4449&view=rev Log: Created a script containing the commands used in the system test for creating a model-free model. The system test executes the script instead of running the commands itself. Added: 1.3/test_suite/system_tests/scripts/create_m4.py Modified: 1.3/test_suite/system_tests/model_free.py Modified: 1.3/test_suite/system_tests/model_free.py URL: http://svn.gna.org/viewcvs/relax/1.3/test_suite/system_tests/model_free.py?rev=4449&r1=4448&r2=4449&view=diff ============================================================================== --- 1.3/test_suite/system_tests/model_free.py (original) +++ 1.3/test_suite/system_tests/model_free.py Mon Jan 7 18:09:07 2008 @@ -82,14 +82,11 @@ def test_create_m4(self): """Creating model m4 with parameters {S2, te, Rex} using model_free.create_model().""" - # Path of the files. - path = sys.path[-1] + '/test_suite/system_tests/data/model_free/S2_0.970_te_2048_Rex_0.149' - - # Read the sequence. - self.relax.interpreter._Sequence.read(file='noe.500.out', dir=path) - - # Select the model. - self.relax.interpreter._Model_free.create_model(model='m4', equation='mf_orig', params=['S2', 'te', 'Rex'], spin_id=None) + # Place the script file name into self.relax.script_file. + self.relax.script_file = 'test_suite/system_tests/scripts/create_m4.py' + + # Execute relax in script mode. + self.relax.interpreter.run(quit=False) # Alias the current data pipe. cdp = relax_data_store[relax_data_store.current_pipe] Added: 1.3/test_suite/system_tests/scripts/create_m4.py URL: http://svn.gna.org/viewcvs/relax/1.3/test_suite/system_tests/scripts/create_m4.py?rev=4449&view=auto ============================================================================== --- 1.3/test_suite/system_tests/scripts/create_m4.py (added) +++ 1.3/test_suite/system_tests/scripts/create_m4.py Mon Jan 7 18:09:07 2008 @@ -1,0 +1,14 @@ +"""Script for creating model m4 with parameters {S2, te, Rex}.""" + +# Python module imports. +import sys + + +# Path of the files. +path = sys.path[-1] + '/test_suite/system_tests/data/model_free/S2_0.970_te_2048_Rex_0.149' + +# Read the sequence. +sequence.read(file='noe.500.out', dir=path) + +# Select the model. +model_free.create_model(model='m4', equation='mf_orig', params=['S2', 'te', 'Rex'], spin_id=None)