CreateCommentAsync() public method

Creates a new comment
public CreateCommentAsync ( string caption, string imageId, int parentId = null ) : Task>
caption string The body of the comment
imageId string The image to post the comment on
parentId int [optional] The id of the comment this is a reply to, (if this is a reply)
return Task>
コード例 #1
0
		public async Task TestCreateComment()
		{
			var imgurClient = await AuthenticationHelpers.CreateOAuth2AuthenticatedImgurClient();
			var commentEndpoint = new CommentEndpoint(imgurClient);
			var comment = await commentEndpoint.CreateCommentAsync("test reply", "161n8BB", 193421419);

			// Assert the Reponse
			Assert.IsNotNull(comment.Data);
			Assert.AreEqual(comment.Success, true);
			Assert.AreEqual(comment.Status, HttpStatusCode.OK);
		}