{"action":"created","comment":{"url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/comments/58896956","id":58896956,"diff_hunk":"@@ -0,0 +1,99 @@\n+﻿using System;\n+using System.Net;\n+using System.Threading.Tasks;\n+using System.Xml.XPath;\n+using AutoMoq.Helpers;\n+using Moq;\n+using NUnit.Framework;\n+using Should;\n+\n+namespace SparkPost.Tests\n+{\n+    public class SuppressionTests\n+    {\n+        [TestFixture]\n+        public class DeleteTests : AutoMoqTestFixture<Suppressions>\n+        {\n+            private Response response;\n+            private string email;\n+\n+            [SetUp]\n+            public void Setup()\n+            {\n+                ResetSubject();\n+\n+                response = new Response {StatusCode = HttpStatusCode.NoContent};\n+\n+                Mocked<IRequestSender>()\n+                    .Setup(x => x.Send(It.IsAny<Request>()))\n+                    .Returns(Task.FromResult(response));\n+\n+                email = Guid.NewGuid().ToString();\n+            }\n+\n+            [Test]\n+            public async void It_should_return_true_if_the_web_request_returns_no_content()\n+            {\n+                var result = await Subject.Delete(email);\n+                result.ShouldBeTrue();\n+            }\n+\n+            [Test]\n+            public async void It_should_return_false_if_the_web_request_returns_anything_but_no_content()\n+            {\n+                response.StatusCode = HttpStatusCode.Accepted;\n+                (await Subject.Delete(email)).ShouldBeFalse();\n+\n+                response.StatusCode = HttpStatusCode.Ambiguous;\n+                (await Subject.Delete(email)).ShouldBeFalse();\n+\n+                response.StatusCode = HttpStatusCode.UpgradeRequired;\n+                (await Subject.Delete(email)).ShouldBeFalse();\n+            }\n+\n+            [Test]\n+            public async void It_should_build_the_web_request_parameters_correctly()\n+            {\n+                var version = Guid.NewGuid().ToString();\n+\n+                Mocked<IClient>()\n+                    .Setup(x => x.Version)\n+                    .Returns(version);\n+\n+                Mocked<IRequestSender>()\n+                    .Setup(x => x.Send(It.IsAny<Request>()))\n+                    .Callback((Request r) =>\n+                    {\n+                        r.Url.ShouldEqual($\"api/{version}/suppression-list/{email}\");\n+                        r.Method.ShouldEqual(\"DELETE\");\n+                    })\n+                    .Returns(Task.FromResult(response));\n+\n+                await Subject.Delete(email);\n+            }\n+\n+            [Test]\n+            public async void It_should_encode_the_email_address()\n+            {\n+                var version = Guid.NewGuid().ToString();\n+\n+                email = \"testing@test.com\";","path":"src/SparkPost.Tests/SuppressionTests.cs","position":80,"original_position":80,"commit_id":"3b062823cc2a7ca02fc0527390f946b8d518dbc9","original_commit_id":"3b062823cc2a7ca02fc0527390f946b8d518dbc9","user":{"login":"darrencauthon","id":148768,"avatar_url":"https://avatars.githubusercontent.com/u/148768?v=3","gravatar_id":"","url":"https://api.github.com/users/darrencauthon","html_url":"https://github.com/darrencauthon","followers_url":"https://api.github.com/users/darrencauthon/followers","following_url":"https://api.github.com/users/darrencauthon/following{/other_user}","gists_url":"https://api.github.com/users/darrencauthon/gists{/gist_id}","starred_url":"https://api.github.com/users/darrencauthon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darrencauthon/subscriptions","organizations_url":"https://api.github.com/users/darrencauthon/orgs","repos_url":"https://api.github.com/users/darrencauthon/repos","events_url":"https://api.github.com/users/darrencauthon/events{/privacy}","received_events_url":"https://api.github.com/users/darrencauthon/received_events","type":"User","site_admin":false},"body":"Haha, if they get tired of this, I'd be happy to take their domain.\r\n\r\nNone of the tests actually hit any external web service or fire any emails... so they're safe from me. :smile:  ","created_at":"2016-04-07T15:56:44Z","updated_at":"2016-04-07T15:56:44Z","html_url":"https://github.com/SparkPost/csharp-sparkpost/pull/29#discussion_r58896956","pull_request_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/29","_links":{"self":{"href":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/comments/58896956"},"html":{"href":"https://github.com/SparkPost/csharp-sparkpost/pull/29#discussion_r58896956"},"pull_request":{"href":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/29"}}},"pull_request":{"url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/29","id":65407356,"html_url":"https://github.com/SparkPost/csharp-sparkpost/pull/29","diff_url":"https://github.com/SparkPost/csharp-sparkpost/pull/29.diff","patch_url":"https://github.com/SparkPost/csharp-sparkpost/pull/29.patch","issue_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/issues/29","number":29,"state":"open","locked":false,"title":"Suppression List support, bonus Retrieve Transmission","user":{"login":"darrencauthon","id":148768,"avatar_url":"https://avatars.githubusercontent.com/u/148768?v=3","gravatar_id":"","url":"https://api.github.com/users/darrencauthon","html_url":"https://github.com/darrencauthon","followers_url":"https://api.github.com/users/darrencauthon/followers","following_url":"https://api.github.com/users/darrencauthon/following{/other_user}","gists_url":"https://api.github.com/users/darrencauthon/gists{/gist_id}","starred_url":"https://api.github.com/users/darrencauthon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darrencauthon/subscriptions","organizations_url":"https://api.github.com/users/darrencauthon/orgs","repos_url":"https://api.github.com/users/darrencauthon/repos","events_url":"https://api.github.com/users/darrencauthon/events{/privacy}","received_events_url":"https://api.github.com/users/darrencauthon/received_events","type":"User","site_admin":false},"body":"![fullscreen_040616_065403_am](https://cloud.githubusercontent.com/assets/148768/14315665/6d410022-fbc4-11e5-847c-2ac897f48d08.jpg)\r\n\r\n![screenshot_040616_065824_am](https://cloud.githubusercontent.com/assets/148768/14315820/1e01a4fc-fbc5-11e5-974f-5f3c0dbe6324.jpg)\r\n\r\n![screenshot_040616_070244_am](https://cloud.githubusercontent.com/assets/148768/14315897/90b456fc-fbc5-11e5-8780-1b55f08c8d45.jpg)\r\n\r\n![screenshot_040616_070431_am](https://cloud.githubusercontent.com/assets/148768/14315941/cf855f70-fbc5-11e5-9a65-635d4fe4d8f2.jpg)\r\n\r\n![screenshot_040616_070551_am](https://cloud.githubusercontent.com/assets/148768/14315972/ffaca596-fbc5-11e5-80e6-3274394e32af.jpg)\r\n\r\n![screenshot_040616_070711_am](https://cloud.githubusercontent.com/assets/148768/14316010/2fda9c6e-fbc6-11e5-930f-a7f2b75225d8.jpg)\r\n\r\n![screenshot_040616_071634_am](https://cloud.githubusercontent.com/assets/148768/14316225/7fa6a520-fbc7-11e5-9cf3-8c5e12813908.jpg)\r\n","created_at":"2016-04-06T04:05:09Z","updated_at":"2016-04-07T15:56:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":"39d17f050a7d644fca59c3a98b0cf7aefe2da8be","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/29/commits","review_comments_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/29/comments","review_comment_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/comments{/number}","comments_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/issues/29/comments","statuses_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/statuses/3b062823cc2a7ca02fc0527390f946b8d518dbc9","head":{"label":"SparkPost:playing_with_suppression_list","ref":"playing_with_suppression_list","sha":"3b062823cc2a7ca02fc0527390f946b8d518dbc9","user":{"login":"SparkPost","id":9406778,"avatar_url":"https://avatars.githubusercontent.com/u/9406778?v=3","gravatar_id":"","url":"https://api.github.com/users/SparkPost","html_url":"https://github.com/SparkPost","followers_url":"https://api.github.com/users/SparkPost/followers","following_url":"https://api.github.com/users/SparkPost/following{/other_user}","gists_url":"https://api.github.com/users/SparkPost/gists{/gist_id}","starred_url":"https://api.github.com/users/SparkPost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SparkPost/subscriptions","organizations_url":"https://api.github.com/users/SparkPost/orgs","repos_url":"https://api.github.com/users/SparkPost/repos","events_url":"https://api.github.com/users/SparkPost/events{/privacy}","received_events_url":"https://api.github.com/users/SparkPost/received_events","type":"Organization","site_admin":false},"repo":{"id":52905532,"name":"csharp-sparkpost","full_name":"SparkPost/csharp-sparkpost","owner":{"login":"SparkPost","id":9406778,"avatar_url":"https://avatars.githubusercontent.com/u/9406778?v=3","gravatar_id":"","url":"https://api.github.com/users/SparkPost","html_url":"https://github.com/SparkPost","followers_url":"https://api.github.com/users/SparkPost/followers","following_url":"https://api.github.com/users/SparkPost/following{/other_user}","gists_url":"https://api.github.com/users/SparkPost/gists{/gist_id}","starred_url":"https://api.github.com/users/SparkPost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SparkPost/subscriptions","organizations_url":"https://api.github.com/users/SparkPost/orgs","repos_url":"https://api.github.com/users/SparkPost/repos","events_url":"https://api.github.com/users/SparkPost/events{/privacy}","received_events_url":"https://api.github.com/users/SparkPost/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/SparkPost/csharp-sparkpost","description":"SparkPost client library for the C# Programming Language","fork":false,"url":"https://api.github.com/repos/SparkPost/csharp-sparkpost","forks_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/forks","keys_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/teams","hooks_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/hooks","issue_events_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/issues/events{/number}","events_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/events","assignees_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/assignees{/user}","branches_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/branches{/branch}","tags_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/tags","blobs_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/git/refs{/sha}","trees_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/statuses/{sha}","languages_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/languages","stargazers_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/stargazers","contributors_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/contributors","subscribers_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/subscribers","subscription_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/subscription","commits_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/commits{/sha}","git_commits_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/git/commits{/sha}","comments_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/comments{/number}","issue_comment_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/issues/comments{/number}","contents_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/contents/{+path}","compare_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/merges","archive_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/downloads","issues_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/issues{/number}","pulls_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls{/number}","milestones_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/milestones{/number}","notifications_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/labels{/name}","releases_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/releases{/id}","deployments_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/deployments","created_at":"2016-03-01T19:55:48Z","updated_at":"2016-04-01T18:15:06Z","pushed_at":"2016-04-07T14:07:26Z","git_url":"git://github.com/SparkPost/csharp-sparkpost.git","ssh_url":"git@github.com:SparkPost/csharp-sparkpost.git","clone_url":"https://github.com/SparkPost/csharp-sparkpost.git","svn_url":"https://github.com/SparkPost/csharp-sparkpost","homepage":"https://www.sparkpost.com","size":137,"stargazers_count":12,"watchers_count":12,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"open_issues_count":6,"forks":7,"open_issues":6,"watchers":12,"default_branch":"master"}},"base":{"label":"SparkPost:master","ref":"master","sha":"eb21934481f9b94f6baf36d45110e6dd75369caf","user":{"login":"SparkPost","id":9406778,"avatar_url":"https://avatars.githubusercontent.com/u/9406778?v=3","gravatar_id":"","url":"https://api.github.com/users/SparkPost","html_url":"https://github.com/SparkPost","followers_url":"https://api.github.com/users/SparkPost/followers","following_url":"https://api.github.com/users/SparkPost/following{/other_user}","gists_url":"https://api.github.com/users/SparkPost/gists{/gist_id}","starred_url":"https://api.github.com/users/SparkPost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SparkPost/subscriptions","organizations_url":"https://api.github.com/users/SparkPost/orgs","repos_url":"https://api.github.com/users/SparkPost/repos","events_url":"https://api.github.com/users/SparkPost/events{/privacy}","received_events_url":"https://api.github.com/users/SparkPost/received_events","type":"Organization","site_admin":false},"repo":{"id":52905532,"name":"csharp-sparkpost","full_name":"SparkPost/csharp-sparkpost","owner":{"login":"SparkPost","id":9406778,"avatar_url":"https://avatars.githubusercontent.com/u/9406778?v=3","gravatar_id":"","url":"https://api.github.com/users/SparkPost","html_url":"https://github.com/SparkPost","followers_url":"https://api.github.com/users/SparkPost/followers","following_url":"https://api.github.com/users/SparkPost/following{/other_user}","gists_url":"https://api.github.com/users/SparkPost/gists{/gist_id}","starred_url":"https://api.github.com/users/SparkPost/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SparkPost/subscriptions","organizations_url":"https://api.github.com/users/SparkPost/orgs","repos_url":"https://api.github.com/users/SparkPost/repos","events_url":"https://api.github.com/users/SparkPost/events{/privacy}","received_events_url":"https://api.github.com/users/SparkPost/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/SparkPost/csharp-sparkpost","description":"SparkPost client library for the C# Programming Language","fork":false,"url":"https://api.github.com/repos/SparkPost/csharp-sparkpost","forks_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/forks","keys_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/keys{/key_id}","collaborators_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/teams","hooks_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/hooks","issue_events_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/issues/events{/number}","events_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/events","assignees_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/assignees{/user}","branches_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/branches{/branch}","tags_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/tags","blobs_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/git/refs{/sha}","trees_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/git/trees{/sha}","statuses_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/statuses/{sha}","languages_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/languages","stargazers_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/stargazers","contributors_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/contributors","subscribers_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/subscribers","subscription_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/subscription","commits_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/commits{/sha}","git_commits_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/git/commits{/sha}","comments_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/comments{/number}","issue_comment_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/issues/comments{/number}","contents_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/contents/{+path}","compare_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/compare/{base}...{head}","merges_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/merges","archive_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/downloads","issues_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/issues{/number}","pulls_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls{/number}","milestones_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/milestones{/number}","notifications_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/labels{/name}","releases_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/releases{/id}","deployments_url":"https://api.github.com/repos/SparkPost/csharp-sparkpost/deployments","created_at":"2016-03-01T19:55:48Z","updated_at":"2016-04-01T18:15:06Z","pushed_at":"2016-04-07T14:07:26Z","git_url":"git://github.com/SparkPost/csharp-sparkpost.git","ssh_url":"git@github.com:SparkPost/csharp-sparkpost.git","clone_url":"https://github.com/SparkPost/csharp-sparkpost.git","svn_url":"https://github.com/SparkPost/csharp-sparkpost","homepage":"https://www.sparkpost.com","size":137,"stargazers_count":12,"watchers_count":12,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"open_issues_count":6,"forks":7,"open_issues":6,"watchers":12,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/29"},"html":{"href":"https://github.com/SparkPost/csharp-sparkpost/pull/29"},"issue":{"href":"https://api.github.com/repos/SparkPost/csharp-sparkpost/issues/29"},"comments":{"href":"https://api.github.com/repos/SparkPost/csharp-sparkpost/issues/29/comments"},"review_comments":{"href":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/29/comments"},"review_comment":{"href":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/SparkPost/csharp-sparkpost/pulls/29/commits"},"statuses":{"href":"https://api.github.com/repos/SparkPost/csharp-sparkpost/statuses/3b062823cc2a7ca02fc0527390f946b8d518dbc9"}}}}