Commit 8935a13b authored by Nick Draper's avatar Nick Draper
Browse files

clang formatting for this pr

parent efeedfbb
...@@ -5,8 +5,8 @@ ...@@ -5,8 +5,8 @@
// Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS // Institut Laue - Langevin & CSNS, Institute of High Energy Physics, CAS
// SPDX - License - Identifier: GPL - 3.0 + // SPDX - License - Identifier: GPL - 3.0 +
#include "MantidAlgorithms/RenameWorkspace.h" #include "MantidAlgorithms/RenameWorkspace.h"
#include "MantidAPI/AnalysisDataService.h"
#include "MantidAPI/AlgorithmManager.h" #include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/AnalysisDataService.h"
#include "MantidAPI/MatrixWorkspace.h" #include "MantidAPI/MatrixWorkspace.h"
#include "MantidAPI/WorkspaceGroup.h" #include "MantidAPI/WorkspaceGroup.h"
#include "MantidAPI/WorkspaceHistory.h" #include "MantidAPI/WorkspaceHistory.h"
......
...@@ -8,8 +8,8 @@ ...@@ -8,8 +8,8 @@
#include <cxxtest/TestSuite.h> #include <cxxtest/TestSuite.h>
#include "MantidAPI/Axis.h"
#include "MantidAPI/AlgorithmManager.h" #include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/Axis.h"
#include "MantidAlgorithms/AnyShapeAbsorption.h" #include "MantidAlgorithms/AnyShapeAbsorption.h"
#include "MantidAlgorithms/CylinderAbsorption.h" #include "MantidAlgorithms/CylinderAbsorption.h"
#include "MantidAlgorithms/FlatPlateAbsorption.h" #include "MantidAlgorithms/FlatPlateAbsorption.h"
...@@ -17,8 +17,8 @@ ...@@ -17,8 +17,8 @@
#include "MantidTestHelpers/ComponentCreationHelper.h" #include "MantidTestHelpers/ComponentCreationHelper.h"
#include "MantidTestHelpers/WorkspaceCreationHelper.h" #include "MantidTestHelpers/WorkspaceCreationHelper.h"
using Mantid::API::AnalysisDataService;
using Mantid::API::AlgorithmManager; using Mantid::API::AlgorithmManager;
using Mantid::API::AnalysisDataService;
using Mantid::API::MatrixWorkspace_sptr; using Mantid::API::MatrixWorkspace_sptr;
class AnyShapeAbsorptionTest : public CxxTest::TestSuite { class AnyShapeAbsorptionTest : public CxxTest::TestSuite {
......
...@@ -6,9 +6,9 @@ ...@@ -6,9 +6,9 @@
// SPDX - License - Identifier: GPL - 3.0 + // SPDX - License - Identifier: GPL - 3.0 +
#pragma once #pragma once
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/AnalysisDataService.h" #include "MantidAPI/AnalysisDataService.h"
#include "MantidAPI/Axis.h" #include "MantidAPI/Axis.h"
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/SpectrumInfo.h" #include "MantidAPI/SpectrumInfo.h"
#include "MantidAlgorithms/AppendSpectra.h" #include "MantidAlgorithms/AppendSpectra.h"
#include "MantidDataHandling/LoadRaw3.h" #include "MantidDataHandling/LoadRaw3.h"
...@@ -418,8 +418,7 @@ private: ...@@ -418,8 +418,7 @@ private:
const std::string &inputWorkspace2, const std::string &inputWorkspace2,
const std::string &outputWorkspace) { const std::string &outputWorkspace) {
auto appendSpectra = auto appendSpectra =
Mantid::API::AlgorithmManager::Instance().create( Mantid::API::AlgorithmManager::Instance().create("AppendSpectra");
"AppendSpectra");
TS_ASSERT_THROWS_NOTHING(appendSpectra->setRethrows(true)); TS_ASSERT_THROWS_NOTHING(appendSpectra->setRethrows(true));
TS_ASSERT_THROWS_NOTHING( TS_ASSERT_THROWS_NOTHING(
appendSpectra->setProperty("InputWorkspace1", inputWorkspace1)); appendSpectra->setProperty("InputWorkspace1", inputWorkspace1));
...@@ -449,8 +448,8 @@ private: ...@@ -449,8 +448,8 @@ private:
dataY.emplace_back(double(i)); dataY.emplace_back(double(i));
} }
auto createWS = Mantid::API::AlgorithmManager::Instance().create( auto createWS =
"CreateWorkspace"); Mantid::API::AlgorithmManager::Instance().create("CreateWorkspace");
TS_ASSERT_THROWS_NOTHING(createWS->setProperty("OutputWorkspace", "we")); TS_ASSERT_THROWS_NOTHING(createWS->setProperty("OutputWorkspace", "we"));
TS_ASSERT_THROWS_NOTHING(createWS->setProperty("DataX", dataX)); TS_ASSERT_THROWS_NOTHING(createWS->setProperty("DataX", dataX));
TS_ASSERT_THROWS_NOTHING(createWS->setProperty("DataY", dataY)); TS_ASSERT_THROWS_NOTHING(createWS->setProperty("DataY", dataY));
...@@ -464,8 +463,7 @@ private: ...@@ -464,8 +463,7 @@ private:
TS_ASSERT_THROWS_NOTHING(createWS->execute()); TS_ASSERT_THROWS_NOTHING(createWS->execute());
// we do a rebin so we can have nice bins // we do a rebin so we can have nice bins
auto rebin = auto rebin = Mantid::API::AlgorithmManager::Instance().create("Rebin");
Mantid::API::AlgorithmManager::Instance().create("Rebin");
TS_ASSERT_THROWS_NOTHING(rebin->setProperty("InputWorkspace", "we")); TS_ASSERT_THROWS_NOTHING(rebin->setProperty("InputWorkspace", "we"));
TS_ASSERT_THROWS_NOTHING( TS_ASSERT_THROWS_NOTHING(
rebin->setProperty("Params", std::vector<double>{1})); rebin->setProperty("Params", std::vector<double>{1}));
......
...@@ -9,8 +9,8 @@ ...@@ -9,8 +9,8 @@
#include <cxxtest/TestSuite.h> #include <cxxtest/TestSuite.h>
#include <vector> #include <vector>
#include "MantidAPI/Axis.h"
#include "MantidAPI/AlgorithmManager.h" #include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/Axis.h"
#include "MantidAPI/WorkspaceGroup.h" #include "MantidAPI/WorkspaceGroup.h"
#include "MantidAlgorithms/CalculateCarpenterSampleCorrection.h" #include "MantidAlgorithms/CalculateCarpenterSampleCorrection.h"
#include "MantidDataObjects/WorkspaceCreation.h" #include "MantidDataObjects/WorkspaceCreation.h"
...@@ -85,8 +85,7 @@ public: ...@@ -85,8 +85,7 @@ public:
// convert to wavelength // convert to wavelength
auto convertUnitsAlg = auto convertUnitsAlg =
Mantid::API::AlgorithmManager::Instance().create( Mantid::API::AlgorithmManager::Instance().create("ConvertUnits");
"ConvertUnits");
convertUnitsAlg->setPropertyValue("InputWorkspace", "TestInputWS"); convertUnitsAlg->setPropertyValue("InputWorkspace", "TestInputWS");
convertUnitsAlg->setPropertyValue("OutputWorkspace", "TestInputWS"); convertUnitsAlg->setPropertyValue("OutputWorkspace", "TestInputWS");
convertUnitsAlg->setProperty("Target", "Wavelength"); convertUnitsAlg->setProperty("Target", "Wavelength");
...@@ -141,8 +140,7 @@ public: ...@@ -141,8 +140,7 @@ public:
TS_ASSERT_DELTA(abs_corr_actual[i], abs_corr_expected[i], 0.00001); TS_ASSERT_DELTA(abs_corr_actual[i], abs_corr_expected[i], 0.00001);
// Check applying absorption correction // Check applying absorption correction
auto divide = auto divide = Mantid::API::AlgorithmManager::Instance().create("Divide");
Mantid::API::AlgorithmManager::Instance().create("Divide");
divide->initialize(); divide->initialize();
divide->setPropertyValue("LHSWorkspace", "TestInputWS"); divide->setPropertyValue("LHSWorkspace", "TestInputWS");
divide->setPropertyValue("RHSWorkspace", absWksp->getName()); divide->setPropertyValue("RHSWorkspace", absWksp->getName());
......
...@@ -9,9 +9,9 @@ ...@@ -9,9 +9,9 @@
#include <cxxtest/TestSuite.h> #include <cxxtest/TestSuite.h>
#include <vector> #include <vector>
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/AnalysisDataService.h" #include "MantidAPI/AnalysisDataService.h"
#include "MantidAPI/Axis.h" #include "MantidAPI/Axis.h"
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAlgorithms/CarpenterSampleCorrection.h" #include "MantidAlgorithms/CarpenterSampleCorrection.h"
#include "MantidDataObjects/WorkspaceCreation.h" #include "MantidDataObjects/WorkspaceCreation.h"
#include "MantidHistogramData/LinearGenerator.h" #include "MantidHistogramData/LinearGenerator.h"
...@@ -78,8 +78,7 @@ public: ...@@ -78,8 +78,7 @@ public:
// convert to wavelength // convert to wavelength
auto convertUnitsAlg = auto convertUnitsAlg =
Mantid::API::AlgorithmManager::Instance().create( Mantid::API::AlgorithmManager::Instance().create("ConvertUnits");
"ConvertUnits");
convertUnitsAlg->setPropertyValue("InputWorkspace", "TestInputWS"); convertUnitsAlg->setPropertyValue("InputWorkspace", "TestInputWS");
convertUnitsAlg->setPropertyValue("OutputWorkspace", "TestInputWS"); convertUnitsAlg->setPropertyValue("OutputWorkspace", "TestInputWS");
convertUnitsAlg->setProperty("Target", "Wavelength"); convertUnitsAlg->setProperty("Target", "Wavelength");
......
...@@ -9,9 +9,9 @@ ...@@ -9,9 +9,9 @@
#include "MantidTestHelpers/WorkspaceCreationHelper.h" #include "MantidTestHelpers/WorkspaceCreationHelper.h"
#include <cxxtest/TestSuite.h> #include <cxxtest/TestSuite.h>
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/AnalysisDataService.h" #include "MantidAPI/AnalysisDataService.h"
#include "MantidAPI/Axis.h" #include "MantidAPI/Axis.h"
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/MatrixWorkspace.h" #include "MantidAPI/MatrixWorkspace.h"
#include "MantidAlgorithms/ConvertToDistribution.h" #include "MantidAlgorithms/ConvertToDistribution.h"
#include "MantidAlgorithms/ConvertUnits.h" #include "MantidAlgorithms/ConvertUnits.h"
......
...@@ -8,8 +8,8 @@ ...@@ -8,8 +8,8 @@
#include <cxxtest/TestSuite.h> #include <cxxtest/TestSuite.h>
#include "MantidAPI/AnalysisDataService.h"
#include "MantidAPI/AlgorithmManager.h" #include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/AnalysisDataService.h"
#include "MantidAPI/MatrixWorkspace.h" #include "MantidAPI/MatrixWorkspace.h"
#include "MantidAPI/WorkspaceFactory.h" #include "MantidAPI/WorkspaceFactory.h"
#include "MantidAlgorithms/FFTDerivative.h" #include "MantidAlgorithms/FFTDerivative.h"
...@@ -25,8 +25,8 @@ public: ...@@ -25,8 +25,8 @@ public:
createWS(N, 0, "exp"); createWS(N, 0, "exp");
auto fft = Mantid::API::AlgorithmManager::Instance().create( auto fft =
"FFTDerivative"); Mantid::API::AlgorithmManager::Instance().create("FFTDerivative");
fft->initialize(); fft->initialize();
fft->setPropertyValue("InputWorkspace", "FFTDerivative_WS_exp"); fft->setPropertyValue("InputWorkspace", "FFTDerivative_WS_exp");
fft->setPropertyValue("OutputWorkspace", "FFTDerivative_out"); fft->setPropertyValue("OutputWorkspace", "FFTDerivative_out");
...@@ -54,8 +54,8 @@ public: ...@@ -54,8 +54,8 @@ public:
createWS(N, 0, "exp"); createWS(N, 0, "exp");
auto fft = Mantid::API::AlgorithmManager::Instance().create( auto fft =
"FFTDerivative"); Mantid::API::AlgorithmManager::Instance().create("FFTDerivative");
fft->initialize(); fft->initialize();
fft->setPropertyValue("InputWorkspace", "FFTDerivative_WS_exp"); fft->setPropertyValue("InputWorkspace", "FFTDerivative_WS_exp");
fft->setPropertyValue("OutputWorkspace", "FFTDerivative_out"); fft->setPropertyValue("OutputWorkspace", "FFTDerivative_out");
......
...@@ -9,9 +9,9 @@ ...@@ -9,9 +9,9 @@
#include <cmath> #include <cmath>
#include <cxxtest/TestSuite.h> #include <cxxtest/TestSuite.h>
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/AnalysisDataService.h" #include "MantidAPI/AnalysisDataService.h"
#include "MantidAPI/Axis.h" #include "MantidAPI/Axis.h"
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/MatrixWorkspace.h" #include "MantidAPI/MatrixWorkspace.h"
#include "MantidAPI/WorkspaceFactory.h" #include "MantidAPI/WorkspaceFactory.h"
#include "MantidAPI/WorkspaceGroup.h" #include "MantidAPI/WorkspaceGroup.h"
...@@ -87,8 +87,7 @@ public: ...@@ -87,8 +87,7 @@ public:
MatrixWorkspace_sptr inputWS = createWS(N, 0); MatrixWorkspace_sptr inputWS = createWS(N, 0);
auto fft = auto fft = Mantid::API::AlgorithmManager::Instance().create("FFT");
Mantid::API::AlgorithmManager::Instance().create("FFT");
fft->initialize(); fft->initialize();
fft->setChild(true); fft->setChild(true);
fft->setProperty("InputWorkspace", inputWS); fft->setProperty("InputWorkspace", inputWS);
...@@ -130,8 +129,7 @@ public: ...@@ -130,8 +129,7 @@ public:
auto inputWS = createWS(N, 1); auto inputWS = createWS(N, 1);
auto fft = auto fft = Mantid::API::AlgorithmManager::Instance().create("FFT");
Mantid::API::AlgorithmManager::Instance().create("FFT");
fft->initialize(); fft->initialize();
fft->setChild(true); fft->setChild(true);
fft->setProperty("InputWorkspace", inputWS); fft->setProperty("InputWorkspace", inputWS);
...@@ -167,8 +165,7 @@ public: ...@@ -167,8 +165,7 @@ public:
MatrixWorkspace_sptr inWS = createWS(N, 1); MatrixWorkspace_sptr inWS = createWS(N, 1);
auto fft = auto fft = Mantid::API::AlgorithmManager::Instance().create("FFT");
Mantid::API::AlgorithmManager::Instance().create("FFT");
fft->initialize(); fft->initialize();
fft->setChild(true); fft->setChild(true);
fft->setProperty("InputWorkspace", inWS); fft->setProperty("InputWorkspace", inWS);
...@@ -210,8 +207,7 @@ public: ...@@ -210,8 +207,7 @@ public:
const auto inWS = createWS(N, 0); const auto inWS = createWS(N, 0);
auto fft = auto fft = Mantid::API::AlgorithmManager::Instance().create("FFT");
Mantid::API::AlgorithmManager::Instance().create("FFT");
fft->initialize(); fft->initialize();
fft->setChild(true); fft->setChild(true);
fft->setProperty("InputWorkspace", inWS); fft->setProperty("InputWorkspace", inWS);
...@@ -247,8 +243,7 @@ public: ...@@ -247,8 +243,7 @@ public:
const MatrixWorkspace_sptr inWS = createWS(N, 0); const MatrixWorkspace_sptr inWS = createWS(N, 0);
auto fft = auto fft = Mantid::API::AlgorithmManager::Instance().create("FFT");
Mantid::API::AlgorithmManager::Instance().create("FFT");
fft->initialize(); fft->initialize();
fft->setChild(true); fft->setChild(true);
fft->setProperty("InputWorkspace", inWS); fft->setProperty("InputWorkspace", inWS);
...@@ -291,8 +286,7 @@ public: ...@@ -291,8 +286,7 @@ public:
const auto inWS = createWS(N, 1); const auto inWS = createWS(N, 1);
auto fft = auto fft = Mantid::API::AlgorithmManager::Instance().create("FFT");
Mantid::API::AlgorithmManager::Instance().create("FFT");
fft->initialize(); fft->initialize();
fft->setChild(true); fft->setChild(true);
fft->setProperty("InputWorkspace", inWS); fft->setProperty("InputWorkspace", inWS);
...@@ -328,8 +322,7 @@ public: ...@@ -328,8 +322,7 @@ public:
const MatrixWorkspace_sptr inWS = createWS(N, 1); const MatrixWorkspace_sptr inWS = createWS(N, 1);
auto fft = auto fft = Mantid::API::AlgorithmManager::Instance().create("FFT");
Mantid::API::AlgorithmManager::Instance().create("FFT");
fft->initialize(); fft->initialize();
fft->setChild(true); fft->setChild(true);
fft->setProperty("InputWorkspace", inWS); fft->setProperty("InputWorkspace", inWS);
...@@ -372,8 +365,7 @@ public: ...@@ -372,8 +365,7 @@ public:
const auto realWS = createWS(N, 0); const auto realWS = createWS(N, 0);
const auto imagWS = createWS(N, 0); const auto imagWS = createWS(N, 0);
auto fft = auto fft = Mantid::API::AlgorithmManager::Instance().create("FFT");
Mantid::API::AlgorithmManager::Instance().create("FFT");
fft->initialize(); fft->initialize();
fft->setChild(true); fft->setChild(true);
fft->setProperty("InputWorkspace", realWS); fft->setProperty("InputWorkspace", realWS);
...@@ -422,8 +414,7 @@ public: ...@@ -422,8 +414,7 @@ public:
inWS->getAxis(0)->unit() = inWS->getAxis(0)->unit() =
Mantid::Kernel::UnitFactory::Instance().create("Energy"); Mantid::Kernel::UnitFactory::Instance().create("Energy");
auto fft = auto fft = Mantid::API::AlgorithmManager::Instance().create("FFT");
Mantid::API::AlgorithmManager::Instance().create("FFT");
fft->initialize(); fft->initialize();
fft->setChild(true); fft->setChild(true);
fft->setProperty("InputWorkspace", inWS); fft->setProperty("InputWorkspace", inWS);
...@@ -834,8 +825,7 @@ private: ...@@ -834,8 +825,7 @@ private:
Y.emplace_back(sin(omega * x)); Y.emplace_back(sin(omega * x));
E.emplace_back(0.1); E.emplace_back(0.1);
} }
auto create = auto create = AlgorithmManager::Instance().create("CreateWorkspace");
AlgorithmManager::Instance().create("CreateWorkspace");
create->initialize(); create->initialize();
create->setChild(true); create->setChild(true);
create->setProperty("DataX", X); create->setProperty("DataX", X);
...@@ -873,8 +863,7 @@ private: ...@@ -873,8 +863,7 @@ private:
Y.emplace_back(y); Y.emplace_back(y);
E.emplace_back(0.1); E.emplace_back(0.1);
} }
auto create = auto create = AlgorithmManager::Instance().create("CreateWorkspace");
AlgorithmManager::Instance().create("CreateWorkspace");
create->initialize(); create->initialize();
create->setChild(true); create->setChild(true);
create->setProperty("DataX", X); create->setProperty("DataX", X);
...@@ -921,8 +910,7 @@ private: ...@@ -921,8 +910,7 @@ private:
E.emplace_back(0.1); E.emplace_back(0.1);
} }
// create workspace // create workspace
auto create = auto create = AlgorithmManager::Instance().create("CreateWorkspace");
AlgorithmManager::Instance().create("CreateWorkspace");
create->initialize(); create->initialize();
create->setChild(true); create->setChild(true);
create->setProperty("DataX", X); create->setProperty("DataX", X);
...@@ -968,8 +956,7 @@ private: ...@@ -968,8 +956,7 @@ private:
Y.emplace_back(y); Y.emplace_back(y);
} }
// create workspace // create workspace
auto create = auto create = AlgorithmManager::Instance().create("CreateWorkspace");
AlgorithmManager::Instance().create("CreateWorkspace");
create->initialize(); create->initialize();
create->setChild(true); create->setChild(true);
create->setProperty("DataX", X); create->setProperty("DataX", X);
......
...@@ -8,9 +8,9 @@ ...@@ -8,9 +8,9 @@
#include <cxxtest/TestSuite.h> #include <cxxtest/TestSuite.h>
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/AnalysisDataService.h" #include "MantidAPI/AnalysisDataService.h"
#include "MantidAPI/Axis.h" #include "MantidAPI/Axis.h"
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/MatrixWorkspace.h" #include "MantidAPI/MatrixWorkspace.h"
#include "MantidAPI/TableRow.h" #include "MantidAPI/TableRow.h"
#include "MantidAlgorithms/FitPeaks.h" #include "MantidAlgorithms/FitPeaks.h"
...@@ -39,9 +39,7 @@ private: ...@@ -39,9 +39,7 @@ private:
public: public:
// This pair of boilerplate methods prevent the suite being created statically // This pair of boilerplate methods prevent the suite being created statically
// This means the constructor isn't called when running other tests // This means the constructor isn't called when running other tests
static FitPeaksTest *createSuite() { static FitPeaksTest *createSuite() { return new FitPeaksTest(); }
return new FitPeaksTest();
}
static void destroySuite(FitPeaksTest *suite) { delete suite; } static void destroySuite(FitPeaksTest *suite) { delete suite; }
void test_Init() { void test_Init() {
...@@ -527,8 +525,7 @@ public: ...@@ -527,8 +525,7 @@ public:
std::string input_ws_name("PG3_733"); std::string input_ws_name("PG3_733");
// Start by loading our NXS file // Start by loading our NXS file
auto loader = auto loader = Mantid::API::AlgorithmManager::Instance().create("LoadNexus");
Mantid::API::AlgorithmManager::Instance().create("LoadNexus");
loader->setPropertyValue("Filename", "PG3_733.nxs"); loader->setPropertyValue("Filename", "PG3_733.nxs");
loader->setPropertyValue("OutputWorkspace", input_ws_name); loader->setPropertyValue("OutputWorkspace", input_ws_name);
loader->execute(); loader->execute();
...@@ -610,8 +607,7 @@ public: ...@@ -610,8 +607,7 @@ public:
std::string input_ws_name("PG3_733"); std::string input_ws_name("PG3_733");
// Start by loading our NXS file // Start by loading our NXS file
auto loader = auto loader = Mantid::API::AlgorithmManager::Instance().create("LoadNexus");
Mantid::API::AlgorithmManager::Instance().create("LoadNexus");
loader->setPropertyValue("Filename", "PG3_733.nxs"); loader->setPropertyValue("Filename", "PG3_733.nxs");
loader->setPropertyValue("OutputWorkspace", input_ws_name); loader->setPropertyValue("OutputWorkspace", input_ws_name);
loader->execute(); loader->execute();
......
...@@ -572,8 +572,7 @@ public: ...@@ -572,8 +572,7 @@ public:
void setUp() override { void setUp() override {
if (!ws) { if (!ws) {
// Load some data // Load some data
auto loadalg = auto loadalg = AlgorithmManager::Instance().create("Load");
AlgorithmManager::Instance().create("Load");
loadalg->setRethrows(true); loadalg->setRethrows(true);
loadalg->initialize(); loadalg->initialize();
loadalg->setPropertyValue("Filename", "POLREF00004699.nxs"); loadalg->setPropertyValue("Filename", "POLREF00004699.nxs");
...@@ -581,8 +580,7 @@ public: ...@@ -581,8 +580,7 @@ public:
loadalg->execute(); loadalg->execute();
// Convert units to wavelength // Convert units to wavelength
auto unitsalg = auto unitsalg = AlgorithmManager::Instance().create("ConvertUnits");
AlgorithmManager::Instance().create("ConvertUnits");
unitsalg->initialize(); unitsalg->initialize();
unitsalg->setPropertyValue("InputWorkspace", "testws"); unitsalg->setPropertyValue("InputWorkspace", "testws");
unitsalg->setPropertyValue("OutputWorkspace", "testws"); unitsalg->setPropertyValue("OutputWorkspace", "testws");
......
...@@ -44,8 +44,7 @@ public: ...@@ -44,8 +44,7 @@ public:
m_logWSName = "_det_char_log"; m_logWSName = "_det_char_log";
{ {
auto alg = auto alg = AlgorithmManager::Instance().create("CreateWorkspace");
AlgorithmManager::Instance().create("CreateWorkspace");
alg->setPropertyValue("DataX", alg->setPropertyValue("DataX",
"-1.0,-0.8,-0.6,-0.4,-0.2,0.0,0.2,0.4,0.6,0.8,1.0"); "-1.0,-0.8,-0.6,-0.4,-0.2,0.0,0.2,0.4,0.6,0.8,1.0");
alg->setPropertyValue("DataY", alg->setPropertyValue("DataY",
......
...@@ -6,9 +6,9 @@ ...@@ -6,9 +6,9 @@
// SPDX - License - Identifier: GPL - 3.0 + // SPDX - License - Identifier: GPL - 3.0 +
#pragma once #pragma once
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/AnalysisDataService.h" #include "MantidAPI/AnalysisDataService.h"
#include "MantidAPI/Axis.h" #include "MantidAPI/Axis.h"
#include "MantidAPI/AlgorithmManager.h"
#include "MantidAPI/IAlgorithm.h" #include "MantidAPI/IAlgorithm.h"
#include "MantidAPI/MatrixWorkspace.h" #include "MantidAPI/MatrixWorkspace.h"
#include "MantidAPI/WorkspaceFactory.h" #include "MantidAPI/WorkspaceFactory.h"
...@@ -100,8 +100,7 @@ public: ...@@ -100,8 +100,7 @@ public:
// 1. Run PDFFT // 1. Run PDFFT
auto pdfft = auto pdfft =
Mantid::API::AlgorithmManager::Instance().create( Mantid::API::AlgorithmManager::Instance().create("PDFFourierTransform");
"PDFFourierTransform");
pdfft->initialize(); pdfft->initialize();
pdfft->setProperty("InputWorkspace", ws); pdfft->setProperty("InputWorkspace", ws);
...@@ -136,8 +135,7 @@ public: ...@@ -136,8 +135,7 @@ public:
// 1. Run PDFFT // 1. Run PDFFT
auto pdfft = auto pdfft =