24#include <gmock/gmock.h>
44 notifyPresenterImpl(ev, arg1, arg2);
91 void(std::string
const ¶meter, std::vector<std::string>
const &workspaceNames,
92 std::vector<std::string>
const &domainNames, std::vector<double>
const &values,
93 std::vector<bool>
const &fixes, std::vector<std::string>
const &ties,
94 std::vector<std::string>
const &constraints));
96 std::vector<std::string>, std::vector<std::string>>());
134 void(std::string
const &workspaceName,
WorkspaceIndex workspaceIndex,
double startX,
double endX));
143 void(std::string
const &workspaceName,
WorkspaceIndex workspaceIndex, std::string
const &function));
145 void(std::string
const &workspaceName,
WorkspaceIndex workspaceIndex, std::string
const &function));
147 void(std::string
const &workspaceName,
WorkspaceIndex workspaceIndex, std::string
const &function));
152 std::string(std::string
const &workspaceName,
WorkspaceIndex workspaceIndex,
153 std::string
const &functionIndex));
157 std::string(std::string
const &workspaceName,
WorkspaceIndex workspaceIndex,
158 std::string
const &fullParameter, std::string
const &fullTie));
165 std::string
const &fullParameter,
double newValue));
167 void(std::string
const &workspaceName,
WorkspaceIndex workspaceIndex, std::string
const &fullAttribute,
171 std::string
const &fullParameter, std::string
const &tie));
174 void(std::string
const &workspaceName,
WorkspaceIndex workspaceIndex, std::string
const &fullParameter));
176 std::string
const &functionIndex, std::string
const &constraint));
190 std::string
const &fullParameter,
double value));
194 std::string
const &fullParameter, std::string
const &tie));
196 std::string
const &fullParameter, std::string
const &constraint));
204 std::string
const &fullParameter));
206 std::string
const &fullParameter));
216 std::string,
bool>
const &fitOptions,
217 [[maybe_unused]] std::string
const &filepath =
"")
override {
218 return "# mock python script";
double value
The value of the point.
std::map< DeltaEMode::Type, std::string > index
#define GNU_DIAG_ON_SUGGEST_OVERRIDE
#define GNU_DIAG_OFF_SUGGEST_OVERRIDE
Attribute is a non-fitting parameter.
MOCK_METHOD4(addWorkspaceDomain, void(std::string const &workspaceName, WorkspaceIndex workspaceIndex, double startX, double endX))
MOCK_METHOD1(setFittingMode, void(FittingMode fittingMode))
MOCK_METHOD1(setOutputBaseName, void(std::string const &outputBaseName))
MOCK_METHOD3(setFunction, void(std::string const &workspaceName, WorkspaceIndex workspaceIndex, std::string const &function))
MOCK_CONST_METHOD2(getFullParameter, std::string(MantidQt::MantidWidgets::FitDomainIndex, std::string const ¶meter))
MOCK_METHOD3(removeParameterConstraint, void(std::string const &workspaceName, WorkspaceIndex workspaceIndex, std::string const &fullParameter))
MOCK_METHOD4(updateParameterConstraint, void(std::string const &workspaceName, WorkspaceIndex workspaceIndex, std::string const &functionIndex, std::string const &constraint))
MOCK_CONST_METHOD0(getFittingMode, FittingMode())
MOCK_CONST_METHOD0(isValid, std::tuple< bool, std::string >())
MOCK_METHOD3(setParameterFixed, void(MantidQt::MantidWidgets::FitDomainIndex domainIndex, std::string const &fullParameter, bool fix))
MOCK_CONST_METHOD2(hasParameter, bool(MantidQt::MantidWidgets::FitDomainIndex domainIndex, std::string const ¶meter))
MOCK_METHOD3(setParameterValue, void(MantidQt::MantidWidgets::FitDomainIndex domainIndex, std::string const &fullParameter, double value))
MOCK_CONST_METHOD2(getParameterConstraint, std::string(MantidQt::MantidWidgets::FitDomainIndex domainIndex, std::string const &fullParameter))
MOCK_METHOD3(setParameterTie, void(MantidQt::MantidWidgets::FitDomainIndex domainIndex, std::string const &fullParameter, std::string const &tie))
MOCK_CONST_METHOD0(isSimultaneousMode, bool())
MOCK_CONST_METHOD3(getEquivalentFunctionIndexForDomain, std::string(std::string const &workspaceName, WorkspaceIndex workspaceIndex, std::string const &functionIndex))
MOCK_CONST_METHOD1(getDomainName, std::string(MantidQt::MantidWidgets::FitDomainIndex domainIndex))
MOCK_METHOD4(updateParameterValue, void(std::string const &workspaceName, WorkspaceIndex workspaceIndex, std::string const &fullParameter, double newValue))
MOCK_CONST_METHOD2(getEquivalentFunctionIndexForDomain, std::string(MantidQt::MantidWidgets::FitDomainIndex, std::string const &functionIndex))
MOCK_METHOD1(removeDomain, void(MantidQt::MantidWidgets::FitDomainIndex domainIndex))
MOCK_CONST_METHOD0(numberOfDomains, std::size_t())
MOCK_METHOD3(setParameterConstraint, void(MantidQt::MantidWidgets::FitDomainIndex domainIndex, std::string const &fullParameter, std::string const &constraint))
MOCK_METHOD1(setGlobalParameters, void(std::vector< std::string > const ¶meters))
MOCK_CONST_METHOD2(getFullTie, std::string(MantidQt::MantidWidgets::FitDomainIndex, std::string const &tie))
MOCK_CONST_METHOD2(getParameterValue, double(MantidQt::MantidWidgets::FitDomainIndex domainIndex, std::string const &fullParameter))
MOCK_CONST_METHOD2(getParameterTie, std::string(MantidQt::MantidWidgets::FitDomainIndex domainIndex, std::string const &fullParameter))
MOCK_CONST_METHOD0(getGlobalTies, std::vector< GlobalTie >())
std::string generatePythonFitScript(std::tuple< std::string, std::string, std::string, std::string, std::string, bool > const &fitOptions, std::string const &filepath="") override
MOCK_METHOD4(updateAttributeValue, void(std::string const &workspaceName, WorkspaceIndex workspaceIndex, std::string const &fullAttribute, Mantid::API::IFunction::Attribute const &newValue))
MOCK_METHOD1(subscribePresenter, void(IFitScriptGeneratorPresenter *presenter))
MOCK_CONST_METHOD2(hasWorkspaceDomain, bool(std::string const &workspaceName, WorkspaceIndex workspaceIndex))
MOCK_METHOD2(renameWorkspace, void(std::string const &workspaceName, std::string const &newName))
MOCK_CONST_METHOD2(isParameterFixed, bool(MantidQt::MantidWidgets::FitDomainIndex domainIndex, std::string const &fullParameter))
MOCK_CONST_METHOD4(getEquivalentParameterTieForDomain, std::string(std::string const &workspaceName, WorkspaceIndex workspaceIndex, std::string const &fullParameter, std::string const &fullTie))
MOCK_METHOD3(updateEndX, bool(std::string const &workspaceName, WorkspaceIndex workspaceIndex, double endX))
MOCK_METHOD3(updateStartX, bool(std::string const &workspaceName, WorkspaceIndex workspaceIndex, double startX))
MOCK_METHOD4(updateParameterTie, void(std::string const &workspaceName, WorkspaceIndex workspaceIndex, std::string const &fullParameter, std::string const &tie))
MOCK_METHOD3(addFunction, void(std::string const &workspaceName, WorkspaceIndex workspaceIndex, std::string const &function))
MOCK_CONST_METHOD2(getFunction, Mantid::API::IFunction_sptr(std::string const &workspaceName, WorkspaceIndex workspaceIndex))
MOCK_CONST_METHOD1(getAdjustedFunctionIndex, std::string(std::string const ¶meter))
MOCK_METHOD3(removeFunction, void(std::string const &workspaceName, WorkspaceIndex workspaceIndex, std::string const &function))
MOCK_CONST_METHOD0(getGlobalParameters, std::vector< GlobalParameter >())
FitScriptGeneratorView * m_view
MOCK_METHOD1(setGlobalTies, void(std::vector< GlobalTie > const &globalTies))
MOCK_METHOD3(notifyPresenterImpl, void(ViewEvent const &ev, std::string const &arg1, std::string const &arg2))
MockFitScriptGeneratorPresenter(FitScriptGeneratorModel *model)
MOCK_METHOD2(notifyPresenter, void(ViewEvent const &ev, FittingMode fittingMode))
MOCK_METHOD1(setGlobalParameters, void(std::vector< GlobalParameter > const &globalParameters))
FitScriptGeneratorModel * m_model
void notifyPresenter(ViewEvent const &ev, std::string const &arg1="", std::string const &arg2="") override
MockFitScriptGeneratorPresenter(FitScriptGeneratorView *view)
MOCK_METHOD0(openFitScriptGenerator, void())
MOCK_METHOD2(notifyPresenter, void(ViewEvent const &ev, std::vector< std::string > const &vec))
MOCK_METHOD1(setSimultaneousMode, void(bool simultaneousMode))
MOCK_METHOD2(renameWorkspace, void(std::string const &workspaceName, std::string const &newName))
MOCK_CONST_METHOD1(attributeValue, Mantid::API::IFunction::Attribute(std::string const &attribute))
MOCK_CONST_METHOD0(getEditLocalParameterResults, std::tuple< std::string, std::vector< double >, std::vector< bool >, std::vector< std::string >, std::vector< std::string > >())
MOCK_CONST_METHOD0(addWorkspaceDialog, AddWorkspaceDialog *())
MOCK_CONST_METHOD1(workspaceIndex, WorkspaceIndex(FitDomainIndex index))
MOCK_CONST_METHOD1(endX, double(FitDomainIndex index))
MOCK_METHOD0(clearFunction, void())
MOCK_CONST_METHOD0(allRows, std::vector< FitDomainIndex >())
MOCK_METHOD1(removeDomain, void(MantidQt::MantidWidgets::FitDomainIndex domainIndex))
MOCK_CONST_METHOD0(tableWidget, FitScriptGeneratorDataTable *())
MOCK_CONST_METHOD0(applyFunctionChangesToAll, bool())
MOCK_CONST_METHOD0(selectedRows, std::vector< FitDomainIndex >())
MOCK_CONST_METHOD0(outputBaseName, std::string())
MOCK_CONST_METHOD0(filepath, std::string())
MOCK_METHOD1(setSuccessText, void(std::string const &text))
MOCK_CONST_METHOD1(saveTextToClipboard, void(std::string const &text))
MOCK_CONST_METHOD0(addWorkspaceButton, QPushButton *())
MOCK_METHOD4(addWorkspaceDomain, void(std::string const &workspaceName, WorkspaceIndex workspaceIndex, double startX, double endX))
MOCK_CONST_METHOD0(currentRow, FitDomainIndex())
MOCK_CONST_METHOD0(hasLoadedData, bool())
MOCK_METHOD1(setGlobalParameters, void(std::vector< GlobalParameter > const &globalParameter))
MOCK_METHOD1(subscribePresenter, void(IFitScriptGeneratorPresenter *presenter))
MOCK_METHOD7(openEditLocalParameterDialog, void(std::string const ¶meter, std::vector< std::string > const &workspaceNames, std::vector< std::string > const &domainNames, std::vector< double > const &values, std::vector< bool > const &fixes, std::vector< std::string > const &ties, std::vector< std::string > const &constraints))
MOCK_METHOD0(openAddWorkspaceDialog, void())
MOCK_CONST_METHOD0(getDialogWorkspaceIndices, std::vector< WorkspaceIndex >())
MOCK_CONST_METHOD1(workspaceName, std::string(FitDomainIndex index))
MOCK_CONST_METHOD1(startX, double(FitDomainIndex index))
MOCK_METHOD0(resetSelection, void())
MOCK_CONST_METHOD0(generateScriptToClipboardButton, QPushButton *())
MOCK_CONST_METHOD0(removeButton, QPushButton *())
MOCK_CONST_METHOD0(generateScriptToFileButton, QPushButton *())
MOCK_METHOD1(setGlobalTies, void(std::vector< GlobalTie > const &globalTies))
MOCK_CONST_METHOD0(fitOptions, std::tuple< std::string, std::string, std::string, std::string, std::string, bool >())
MOCK_METHOD1(displayWarning, void(std::string const &message))
MOCK_METHOD0(getDialogWorkspaces, std::vector< Mantid::API::MatrixWorkspace_const_sptr >())
MOCK_CONST_METHOD1(parameterValue, double(std::string const ¶meter))
MOCK_CONST_METHOD1(setFunction, void(Mantid::API::IFunction_sptr const &function))
std::shared_ptr< IFunction > IFunction_sptr
shared pointer to the function base class