Skip to content

Latest commit

 

History

History
209 lines (175 loc) · 8.44 KB

ISISSANSGUITests.rst

File metadata and controls

209 lines (175 loc) · 8.44 KB

SANS GUI Testing

Time required: about 1 hour


  1. Get the Training data from the downloads page on the Mantid Project website.
  2. Open Interfaces > SANS > ISIS SANS.
  3. Click Manage Directories. This opens Mantid's main dialog for managing search paths. Ensure the Training data directory is in the search directories.
  4. If you haven't set one up yet, add a folder to save test data into later.
  5. Set the default save directory in Manage Directories
  6. Click OK on the manage-directories dialog and ensure the Save Path on the SANS GUI (below batch file) displays the correct save path.
  7. Click Load User File; from the Training data in the loqdemo folder, choose MaskFile.toml.
  8. Click Load Batch File; from the Training data in the loqdemo folder, choose batch_mode_reduction.csv.
  1. Switch between 1D and 2D at the bottom of the screen, it should automatically switch between CanSAS and NXcanSAS
  2. Change any of the tick boxes (e.g. tick RKH), and switch between 1D and 2D. It should not change.

In the Runs tab:

  1. Check that the Insert, Delete, Copy, Paste, Cut and Erase icons work as expected on table rows.
  2. Tick the Sample Geometry button - some extra columns should appear.
  3. Create multiple rows in the table with different data e.g. one row with an output name, one row without.
  4. Try changing a random setting in the settings tab and remember what you set it to.
  5. Make some more edits to the table. Check that the setting is still showing the value you changed it to, rather than the original.
  6. Click the Export Table button and save the table as a csv file. Check the file in an editor or Excel and ensure it looks like a sensible representation of the table in the format key,value,key,value,.... All columns except Options and Sample Shape should be included.
  7. Try unticking Sample Geometry and ticking Multi-period and resave the CSV. The displayed columns change but the saved file should contain the same set of columns regardless of whether these are ticked.
  8. Click Load Batch file and select the newly saved table. All columns that were saved should be loaded.
  9. Try deleting and/or reordering some of the columns in the saved file and re-load it. All of the values in the file should be populated in the correct columns.
  10. Check again that the setting you changed is still showing the value you changed it to, rather than the original.
  11. Re-load the original batch file.
  1. Change some values on the Settings and Beam Centre tabs.
  2. Re-load the user file and check the values you changed - they should have reverted to their original values.
  3. Ensure that you can load the old style MaskFile.txt user file from the sample data.
  4. In the table on the Runs tab, under the User File column, enter MaskFile.toml in one row and MaskFile.txt in the other row. Click Process All. After some seconds, the rows should turn green to indicate that they processed successfully.
  5. Re-load the original user and batch files as per the set-up instructions.

In the Settings tab:

  1. Go to Mask.
  2. Click Display Mask.
  3. This should give an instrument view with a circle at the centre.
  4. Go to Q, Wavelength, Detector Limits sub-tab.
  5. Close the Instrument View window
  6. Change the Phi Limit to read 0 to 45 and uncheck use mirror sector.
  7. Go to Mask sub-tab.
  8. Click Display Mask.
  9. This should give an instrument view where only angles 0-45 are unmasked.
  10. Change the settings back to -90 to 90 and reselect use mirror sector.

1D reduction

  1. In General, Scale, Event Slice, Sample sub-tab, ensure the Reduction Mode is All.
  2. In the Runs tab, under Save Options, select Both, and tick CanSAS (1D) and NXcanSAS (1D/2D).
  3. Click Process All.
  4. After some seconds the rows should turn green.
  5. In the workspaces list, there should be a series of new workspaces; four group workspaces and four 1D workspaces.
  6. Check your default save directory. For each reduction two banks (HAB/main) should be saved. In total there should be 8 workspaces (4 .xml and 4 .nxs) saved.
  7. Clear the newly created files and workspaces to make the next test easier
  8. Double-click the 1D workspaces and you should get a single line plot.
  9. Change the contents of the first cell in the first row to 74045 and click Process Selected.
  10. The row should turn blue; hovering over the row should give an error message.
  11. Change the first column of the first row back to 74044.
  12. Click on another row, the modified row should have cleared its colour

2D reduction

  1. Switch to 2D and manually untick CanSAS (since we have manually changed the save options at this point)
  2. Tick the Plot Results box.
  3. Click Process All.
  4. A plot window will open; initially empty, then with a line.
  5. You should get four 2D workspaces instead of the previous 1D workspaces (they will have 100 spectra instead of 1). Double-click them and check you can do a colourfill plot.
  6. Check your save directory. There should now only be a .h5 file for each output.
  7. Clear the newly created files and workspaces to make future tests easier
  8. Change Reduction back to 1D.
  9. Click Process All.
  10. A new plot window should open and you should end up with multiple lines plotted.
  11. Check the Multi-period box - six additional columns should appear in the table.
  12. Delete all rows and re-load the batch file.

Merged reduction

  1. In the Settings tab, General, Scale, Event Slice, Sample sub-tab, set Reduction Mode to Merged.
  2. Return to the Runs tab.
  3. Ensure Plot results is ticked and that save outputs CanSAS (1D) and NXcanSAS (1D/2D) are ticked.
  4. Click Process All.
  5. This should result in a plot with six lines.
  6. The workspaces list should now contain a group named LAB_and_HAB_workspaces_from_merged_reduction that contains the main and HAB workspaces, which were previously ungrouped for a non-merged reduction.
  7. Check your save directory. As well as the previous 1D outputs, there should now be an additional .xml and .h5 output file for the merged output for each row.
  8. In the Settings tab, General, Scale, Event Slice, Sample sub-tab, change the Reduction Mode back to All.

In the Beam centre tab:

  1. Make a note of the four values representing the front/main detector centre positions.
  2. Check that detector is set to main-detector and click run.
  3. Check the values in the first row (Centre Position - Rear) have changed on completion.
  4. Change the detector to Hab and re-run ensuring only the values for the front has changed.
  5. For both a plot should appear, as the centre finder is running with four lines.
  6. The four lines should gradually get closer together.

In the Sum Runs tab:

  1. Enter 74044, 74019 in the top line.
  2. Click Add at the side.
  3. Enter LOQ74044-add as Output file.
  4. In the top-right, click Select Save Directory and select a directory in your managed paths.
  5. Click Sum at the bottom.
  6. Go back to the Runs tab.
  7. Remove all rows.
  8. Reload the batch file as before.
  9. Change the first column of both rows to LOQ74044-add.
  10. Click Process All.
  11. This should now process as before.

In the Diagnostic Page tab:

  1. For run choose Browse and load the LOQ74044.nxs file.
  2. Click each of the Integral buttons.
  3. They should produce plots.
  4. Check the Apply Mask boxes and click the buttons again.
  5. They should produce new, slightly different plots.
  1. In the Runs tab, check that all table, process, and load buttons have clear tooltips by hovering over them.
  2. Check that Zero Error Free`, ``Use Optimizations, and Plot Results have clear tooltips.
  3. In the settings, hover over a random selection of buttons and text boxes to check tooltips are still there. Users rely on the tooltips a lot and really do notice each missing one.