Skip to content

Commit

Permalink
Re #10681 Minor comments and bugs found while changing system tests
Browse files Browse the repository at this point in the history
  • Loading branch information
abuts committed Dec 5, 2014
1 parent 8867180 commit 042119f
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 19 deletions.
2 changes: 1 addition & 1 deletion Code/Mantid/scripts/Inelastic/DirectEnergyConversion.py
Expand Up @@ -606,7 +606,7 @@ def convert_to_energy_transfer(self,wb_run=None,sample_run=None,ei_guess=None,re

#the D.E.C. tries to be too clever so we have to fool it into thinking the raw file is already exists as a workspace
sum_name=self.prop_man.instr_name+str(self.prop_man.sample_run[0])+'-sum'
sample_run =self.sum_files(sum_name, sample_run)
sample_run =self.sum_files(sum_name, self.prop_man.sample_run)
common.apply_calibration(self.prop_man.instr_name,sample_run,self.prop_man.det_cal_file)
self.prop_man.sample_run = sample_run

Expand Down
5 changes: 3 additions & 2 deletions Code/Mantid/scripts/Inelastic/DirectPropertyManager.py
Expand Up @@ -54,7 +54,7 @@ def __get__(self,instance,owner=None):
""" return rmm for vanadium """
return 50.9415;
def __set__(self,instance,value):
raise AttributeError(("Can not change vanadium rmm"));
raise AttributeError("Can not change vanadium rmm");
#end VanadiumRMM
#
class DetCalFile(object):
Expand Down Expand Up @@ -246,7 +246,8 @@ def convert_to_list(self,spectra_list):
return result

#end SpectraToMonitorsList
# format to save data

# format(s) to save data
class SaveFormat(object):
# formats available for saving
save_formats = ['spe','nxspe','nxs'];
Expand Down
13 changes: 11 additions & 2 deletions Code/Mantid/scripts/Inelastic/ReductionWrapper.py
Expand Up @@ -93,9 +93,18 @@ def using_web_data(self):
def iliad(F):
def iliad_wrapper(*args):
#seq = inspect.stack();

host = args[0];
input_file = args[1];
output_directory = args[2];
if len(args)>1:
input_file = args[1];
if len(args)>2:
output_directory = args[2];
else:
output_directory =None
else:
input_file=None
output_directory=None

use_web_variables= False;
if host._web_var and output_directory:
use_web_variables = True;
Expand Down
14 changes: 0 additions & 14 deletions Code/Mantid/scripts/test/ReductionWrapperTest.py
Expand Up @@ -59,22 +59,8 @@ def test_export_advanced_values(self):
self.assertEqual(rv.standard_vars,main_prop);
self.assertEqual(rv.advanced_vars,adv_prop);

# apply them to new properties.
#other_prop = self.prop_man;
#other_prop.set_input_parameters(**(rv.standard_vars));
#simple_prop = other_prop.getChangedProperties();


#other_prop.set_input_parameters(**(rv.advanced_vars));



# look what have changed and compare with initial data.
#all_prop = other_prop.getChangedProperties();

#self.assertEqual(all_initial_prop,all_prop)
#self.assertEqual(adv_initial_prop,adv_prop)

os.remove(file);
fbase,fext = os.path.splitext(file)
fcomp = fbase+'.pyc'
Expand Down

0 comments on commit 042119f

Please sign in to comment.