Skip to content

Commit

Permalink
Enable I/O workspace to be used in ApplyCalibrationTest.h re #5797
Browse files Browse the repository at this point in the history
Signed-off-by: Karl Palmen <karl.palmen@stfc.ac.uk>
  • Loading branch information
KarlPalmen committed Feb 27, 2013
1 parent 3765149 commit afa7bf6
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Code/Mantid/Framework/Algorithms/test/ApplyCalibrationTest.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,11 @@ class ApplyCalibrationTest : public CxxTest::TestSuite

void testExec()
{
// Create workspace with paremeterised instrument
// Create workspace with paremeterised instrument and put into data store
Workspace2D_sptr ws = WorkspaceCreationHelper::create2DWorkspaceWithFullInstrument(3, 10, true);
const std::string wsName("ApplyCabrationWs");
AnalysisDataServiceImpl & dataStore = AnalysisDataService::Instance();
dataStore.add(wsName, ws);

// Create Calibration Table
ITableWorkspace_sptr posTableWs = WorkspaceFactory::Instance().createTable();
Expand All @@ -53,7 +56,7 @@ class ApplyCalibrationTest : public CxxTest::TestSuite
TableRow row = posTableWs->appendRow();
row << i+1 << V3D(1.0,0.01*i,1.0);
}
TS_ASSERT_THROWS_NOTHING(appCalib.setProperty<Workspace2D_sptr>("Workspace", ws ));
TS_ASSERT_THROWS_NOTHING(appCalib.setPropertyValue("Workspace", wsName ));
TS_ASSERT_THROWS_NOTHING(appCalib.setProperty<ITableWorkspace_sptr>("PositionTable", posTableWs ));
TS_ASSERT_THROWS_NOTHING(appCalib.execute());

Expand Down

0 comments on commit afa7bf6

Please sign in to comment.