public void MSWEBSS_S09_TC06_GetWebCollection_Succeed() { GetWebCollectionResponseGetWebCollectionResult getWebCollectionResult = Adapter.GetWebCollection(); bool isVerifiedTitleAndUrl = false; if (getWebCollectionResult.Webs.Length > 0) { foreach (WebDefinition w in getWebCollectionResult.Webs) { if (w.Url.Equals(Common.GetConfigurationPropertyValue("SubSiteUrl", this.Site), StringComparison.OrdinalIgnoreCase) && w.Title.Equals(Common.GetConfigurationPropertyValue("TestSiteTitle", this.Site), StringComparison.OrdinalIgnoreCase)) { isVerifiedTitleAndUrl = true; } if (string.IsNullOrEmpty(w.Url) || string.IsNullOrEmpty(w.Title)) { isVerifiedTitleAndUrl = false; Site.Assert.Fail("It does not return expected Title or Url."); break; } } } Site.CaptureRequirementIfIsTrue( isVerifiedTitleAndUrl, 368, @"[In GetWebCollection] If the operation succeeds, it MUST return the Title and URL properties of all immediate child sites of the context site."); // Verify MS-WEBSS requirement: MS-WEBSS_R373 Site.CaptureRequirementIfIsTrue( isVerifiedTitleAndUrl, 373, @"[In GetWebCollectionSoapOut] This message[GetWebCollectionSoapOut] is the response containing the Title and URL properties of all immediate child sites of the context site."); }
/// <summary> /// This operation is used to get the Title and URL properties of all immediate child sites of the context site. /// </summary> /// <returns>The result of GetWebCollection.</returns> public GetWebCollectionResponseGetWebCollectionResult GetWebCollection() { GetWebCollectionResponseGetWebCollectionResult result = new GetWebCollectionResponseGetWebCollectionResult(); try { result = this.service.GetWebCollection(); // Capture requirements of WebDefinition complex type. if (result.Webs.Length > 0) { this.ValidateWebDefinitionForSubWebCollection(); } this.ValidateGetWebCollection(); this.CaptureTransportRelatedRequirements(); } catch (SoapException exp) { // Capture requirements of detail complex type. this.ValidateDetail(exp.Detail); this.CaptureTransportRelatedRequirements(); throw; } return(result); }
/// <summary> /// This operation is used to get the Title and URL properties of all immediate child sites of the context site. /// </summary> /// <returns>The result of GetWebCollection.</returns> public GetWebCollectionResponseGetWebCollectionResult GetWebCollection() { GetWebCollectionResponseGetWebCollectionResult result = new GetWebCollectionResponseGetWebCollectionResult(); try { result = this.service.GetWebCollection(); // Capture requirements of WebDefinition complex type. if (result.Webs.Length > 0) { this.ValidateWebDefinitionForSubWebCollection(); } this.ValidateGetWebCollection(); this.CaptureTransportRelatedRequirements(); } catch (SoapException exp) { // Capture requirements of detail complex type. this.ValidateDetail(exp.Detail); this.CaptureTransportRelatedRequirements(); throw; } return result; }