MockNamedValue MockActualFunctionCall::returnValue() { checkExpectations(); if (_fulfilledExpectation) return _fulfilledExpectation->returnValue(); return MockNamedValue("no return value"); }
MockNamedValue MockSupport::getData(const SimpleString& name) { MockNamedValue* value = data_.getValueByName(name); if (value == NULL) return MockNamedValue(""); return *value; }
MockNamedValue MockCheckedActualCall::returnValue() { checkExpectations(); if (fulfilledExpectation_) return fulfilledExpectation_->returnValue(); return MockNamedValue("no return value"); }
MockNamedValue MockSupport::returnValue() { if (lastActualFunctionCall_) return lastActualFunctionCall_->returnValue(); return MockNamedValue(""); }
TEST(MockCallTest, shouldReturnDefaultWhenThereIsntAnythingToReturn) { CHECK(mock().returnValue().equals(MockNamedValue(""))); }
MockNamedValue MockExpectedFunctionCall::getParameter(const SimpleString& name) { MockNamedValue * p = parameters_->getValueByName(name); return (p) ? *p : MockNamedValue(""); }
MockNamedValue MockCheckedExpectedCall::getOutputParameter(const SimpleString& name) { MockNamedValue * p = outputParameters_->getValueByName(name); return (p) ? *p : MockNamedValue(""); }
MockNamedValue MockActualCallTrace::returnValue() { return MockNamedValue(""); }