예제 #1
0
        public void Delete()
        {
            Uri        requestUri    = new Uri("http://example.com");
            HttpMethod requestMethod = HttpMethod.DELETE;

            Expect.Call <IClientHttpRequest>(requestFactory.CreateRequest(requestUri, requestMethod)).Return(request);
            ExpectGetResponse();
            Expect.Call <bool>(errorHandler.HasError(requestUri, requestMethod, response)).Return(false);

            mocks.ReplayAll();

            template.Delete("http://example.com");
        }
예제 #2
0
 public void DeleteBookmark(int bookmarkId)
 {
     EnsureIsAuthorized();
     _restTemplate.Delete("bookmarks/" + bookmarkId);
 }