Пример #1
0
        public void DeletePageUpdate_WhileSupportedValidCredentials_ReturnTrue(WireDataFormat format)
        {
            //arrage
            var client = TestContext.CreateClientValidCredentials(format);
            var fundraisingResource = new PageApi(client.HttpChannel);
            var validUpdateRequest = ValidUpdateRequest();
            var validRegisterPageRequest = ValidRegisterPageRequest();
            fundraisingResource.Create(validRegisterPageRequest);
            fundraisingResource.PageUpdatesAddPost(validRegisterPageRequest.PageShortName,
                                                   validUpdateRequest);
            var pageUpdatesResult = fundraisingResource.PageUpdates(validRegisterPageRequest.PageShortName);
            var update = pageUpdatesResult.First();

            //act
            var result = fundraisingResource.DeletePageUpdate(validRegisterPageRequest.PageShortName, update.Id.Value);

            //assert
            Assert.IsTrue(result);
        }