From 0cbfe355e94cf41c6af3ff11f2b66643f0772eb0 Mon Sep 17 00:00:00 2001 From: Karl Palmen Date: Fri, 20 Dec 2013 11:34:23 +0000 Subject: [PATCH] Add a not yet correct test of a parameter re #8398 Test does not pass because it is not yet correct. Do not git checkbuild. Signed-off-by: Karl Palmen --- .../test/LoadFullprofResolutionTest.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Code/Mantid/Framework/DataHandling/test/LoadFullprofResolutionTest.h b/Code/Mantid/Framework/DataHandling/test/LoadFullprofResolutionTest.h index 3be2ede3cd29..63330d411883 100644 --- a/Code/Mantid/Framework/DataHandling/test/LoadFullprofResolutionTest.h +++ b/Code/Mantid/Framework/DataHandling/test/LoadFullprofResolutionTest.h @@ -8,6 +8,9 @@ #include "MantidAPI/TableRow.h" #include "MantidDataHandling/LoadInstrument.h" #include "MantidDataObjects/Workspace2D.h" +#include "MantidGeometry/Instrument.h" +#include "MantidGeometry/Instrument/Component.h" +#include "MantidGeometry/Instrument/FitParameter.h" #include #include @@ -297,6 +300,18 @@ class LoadFullprofResolutionTest : public CxxTest::TestSuite TS_ASSERT(alg.isExecuted()); // Check parameters in workspace + MatrixWorkspace_sptr ws; + ws = AnalysisDataService::Instance().retrieveWS(wsName); + Mantid::Geometry::ParameterMap& paramMap = ws->instrumentParameters(); + boost::shared_ptr instr = ws->getInstrument(); + + + Mantid::Geometry::Parameter_sptr alpha0Param = paramMap.get(&(*instr), "IkedaCarpenterPV:Alpha0", "fitting"); + TS_ASSERT(alpha0Param); + if(alpha0Param) { + const Mantid::Geometry::FitParameter& fitParam1 = alpha0Param->value(); + TS_ASSERT_DELTA( fitParam1.getValue(), 100.0, 0.0001); + } // Clean Poco::File("TestWorskpace.irf").remove();