public void SetUp() { var businessObjectProviderStub = MockRepository.GenerateStub <IBusinessObjectProvider>(); businessObjectProviderStub.Stub(_ => _.GetNotAccessiblePropertyStringPlaceHolder()).Return("X"); _result = new NotAccessibleBusinessObjectPropertyPathResult(businessObjectProviderStub); }
private string GetResultString(IBusinessObjectPropertyPathResult result, BocListRow row) { try { return(result.GetString(null)); } catch (Exception e) { s_log.ErrorFormat( e, "Exception thrown while reading string value for property path '{0}' in row {1} of BocList.", _propertyPath.Identifier, row.Index); return(null); } }
public void SetUp() { _mockRepository = new MockRepository(); var businessObjectProviderStub = MockRepository.GenerateStub <IBusinessObjectProvider>(); businessObjectProviderStub.Stub(_ => _.GetNotAccessiblePropertyStringPlaceHolder()).Return("X"); _businessObjectClassWithIdentityStub = MockRepository.GenerateStub <IBusinessObjectClassWithIdentity>(); _businessObjectClassWithIdentityStub.Stub(_ => _.BusinessObjectProvider).Return(businessObjectProviderStub); _businessObjectWithIdentityMock = _mockRepository.StrictMock <IBusinessObjectWithIdentity>(); _businessObjectWithIdentityMock.Stub(_ => _.BusinessObjectClass).Return(_businessObjectClassWithIdentityStub); _propertyMock = _mockRepository.StrictMock <IBusinessObjectProperty>(); _propertyMock.Stub(_ => _.Identifier).Return("Property"); _result = new EvaluatedBusinessObjectPropertyPathResult(_businessObjectWithIdentityMock, _propertyMock); }
public void SetUp() { _result = new NullBusinessObjectPropertyPathResult(); }