{"action":"created","comment":{"url":"https://api.github.com/repos/aspnet/Mvc/pulls/comments/44958030","id":44958030,"diff_hunk":"@@ -120,6 +121,42 @@ public void Constructor_SetsContentType()\n             Assert.Equal(\"attachment; filename=filename.ext; filename*=UTF-8''filename.ext\", httpContext.Response.Headers[\"Content-Disposition\"]);\n         }\n \n+        [Fact]\n+        public void ExecuteResultAsync_ThrowsException_IfCannotResolveLoggerFactory()\n+        {\n+            // Arrange\n+            var httpContext = new DefaultHttpContext();\n+            httpContext.RequestServices = new ServiceCollection().BuildServiceProvider();\n+            var actionContext = CreateActionContext(httpContext);\n+            var result = new EmptyFileResult(\"application/my-type\");\n+\n+            // Act\n+            Action act = () => result.ExecuteResultAsync(actionContext).Wait();\n+\n+            // Assert\n+            Assert.Throws<InvalidOperationException>(act);\n+        }\n+\n+        [Fact]\n+        public async Task ExecuteResultAsync_LogsInformation_IfCanResolveLoggerFactory()\n+        {\n+            // Arrange\n+            var httpContext = new DefaultHttpContext();\n+            var services = new ServiceCollection();\n+            var loggerSink = new TestSink();\n+            services.AddSingleton<ILoggerFactory>(new TestLoggerFactory(loggerSink, true));\n+            httpContext.RequestServices = services.BuildServiceProvider();\n+\n+            var actionContext = CreateActionContext(httpContext);\n+            var result = new EmptyFileResult(\"application/my-type\");\n+\n+            // Act\n+            await result.ExecuteResultAsync(actionContext);\n+\n+            // Assert\n+            Assert.True(loggerSink.Writes.Count == 1);","path":"test/Microsoft.AspNet.Mvc.Core.Test/FileResultTest.cs","position":45,"original_position":45,"commit_id":"b4b9693aa0942804f9e9b4bddf18f7043129b222","original_commit_id":"b4b9693aa0942804f9e9b4bddf18f7043129b222","user":{"login":"Eilon","id":202643,"avatar_url":"https://avatars.githubusercontent.com/u/202643?v=3","gravatar_id":"","url":"https://api.github.com/users/Eilon","html_url":"https://github.com/Eilon","followers_url":"https://api.github.com/users/Eilon/followers","following_url":"https://api.github.com/users/Eilon/following{/other_user}","gists_url":"https://api.github.com/users/Eilon/gists{/gist_id}","starred_url":"https://api.github.com/users/Eilon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Eilon/subscriptions","organizations_url":"https://api.github.com/users/Eilon/orgs","repos_url":"https://api.github.com/users/Eilon/repos","events_url":"https://api.github.com/users/Eilon/events{/privacy}","received_events_url":"https://api.github.com/users/Eilon/received_events","type":"User","site_admin":false},"body":"Use `Assert.Equals(expected, actual);`","created_at":"2015-11-16T18:00:41Z","updated_at":"2015-11-16T18:00:41Z","html_url":"https://github.com/aspnet/Mvc/pull/3559#discussion_r44958030","pull_request_url":"https://api.github.com/repos/aspnet/Mvc/pulls/3559","_links":{"self":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/comments/44958030"},"html":{"href":"https://github.com/aspnet/Mvc/pull/3559#discussion_r44958030"},"pull_request":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/3559"}}},"pull_request":{"url":"https://api.github.com/repos/aspnet/Mvc/pulls/3559","id":50728466,"html_url":"https://github.com/aspnet/Mvc/pull/3559","diff_url":"https://github.com/aspnet/Mvc/pull/3559.diff","patch_url":"https://github.com/aspnet/Mvc/pull/3559.patch","issue_url":"https://api.github.com/repos/aspnet/Mvc/issues/3559","number":3559,"state":"open","locked":false,"title":"Removes unnecessary null check","user":{"login":"herecydev","id":11328618,"avatar_url":"https://avatars.githubusercontent.com/u/11328618?v=3","gravatar_id":"","url":"https://api.github.com/users/herecydev","html_url":"https://github.com/herecydev","followers_url":"https://api.github.com/users/herecydev/followers","following_url":"https://api.github.com/users/herecydev/following{/other_user}","gists_url":"https://api.github.com/users/herecydev/gists{/gist_id}","starred_url":"https://api.github.com/users/herecydev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/herecydev/subscriptions","organizations_url":"https://api.github.com/users/herecydev/orgs","repos_url":"https://api.github.com/users/herecydev/repos","events_url":"https://api.github.com/users/herecydev/events{/privacy}","received_events_url":"https://api.github.com/users/herecydev/received_events","type":"User","site_admin":false},"body":"Resolves #3558 ","created_at":"2015-11-14T18:04:01Z","updated_at":"2015-11-16T18:00:41Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5a6f5db72ab19baa6efed4c731229d4d79540a16","assignee":{"login":"pranavkm","id":174281,"avatar_url":"https://avatars.githubusercontent.com/u/174281?v=3","gravatar_id":"","url":"https://api.github.com/users/pranavkm","html_url":"https://github.com/pranavkm","followers_url":"https://api.github.com/users/pranavkm/followers","following_url":"https://api.github.com/users/pranavkm/following{/other_user}","gists_url":"https://api.github.com/users/pranavkm/gists{/gist_id}","starred_url":"https://api.github.com/users/pranavkm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pranavkm/subscriptions","organizations_url":"https://api.github.com/users/pranavkm/orgs","repos_url":"https://api.github.com/users/pranavkm/repos","events_url":"https://api.github.com/users/pranavkm/events{/privacy}","received_events_url":"https://api.github.com/users/pranavkm/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/aspnet/Mvc/pulls/3559/commits","review_comments_url":"https://api.github.com/repos/aspnet/Mvc/pulls/3559/comments","review_comment_url":"https://api.github.com/repos/aspnet/Mvc/pulls/comments{/number}","comments_url":"https://api.github.com/repos/aspnet/Mvc/issues/3559/comments","statuses_url":"https://api.github.com/repos/aspnet/Mvc/statuses/b4b9693aa0942804f9e9b4bddf18f7043129b222","head":{"label":"herecydev:dev","ref":"dev","sha":"b4b9693aa0942804f9e9b4bddf18f7043129b222","user":{"login":"herecydev","id":11328618,"avatar_url":"https://avatars.githubusercontent.com/u/11328618?v=3","gravatar_id":"","url":"https://api.github.com/users/herecydev","html_url":"https://github.com/herecydev","followers_url":"https://api.github.com/users/herecydev/followers","following_url":"https://api.github.com/users/herecydev/following{/other_user}","gists_url":"https://api.github.com/users/herecydev/gists{/gist_id}","starred_url":"https://api.github.com/users/herecydev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/herecydev/subscriptions","organizations_url":"https://api.github.com/users/herecydev/orgs","repos_url":"https://api.github.com/users/herecydev/repos","events_url":"https://api.github.com/users/herecydev/events{/privacy}","received_events_url":"https://api.github.com/users/herecydev/received_events","type":"User","site_admin":false},"repo":{"id":46176856,"name":"Mvc","full_name":"herecydev/Mvc","owner":{"login":"herecydev","id":11328618,"avatar_url":"https://avatars.githubusercontent.com/u/11328618?v=3","gravatar_id":"","url":"https://api.github.com/users/herecydev","html_url":"https://github.com/herecydev","followers_url":"https://api.github.com/users/herecydev/followers","following_url":"https://api.github.com/users/herecydev/following{/other_user}","gists_url":"https://api.github.com/users/herecydev/gists{/gist_id}","starred_url":"https://api.github.com/users/herecydev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/herecydev/subscriptions","organizations_url":"https://api.github.com/users/herecydev/orgs","repos_url":"https://api.github.com/users/herecydev/repos","events_url":"https://api.github.com/users/herecydev/events{/privacy}","received_events_url":"https://api.github.com/users/herecydev/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/herecydev/Mvc","description":"Model view controller framework for building dynamic web sites with clean separation of concerns, including the merged MVC, Web API, and Web Pages w/ Razor.","fork":true,"url":"https://api.github.com/repos/herecydev/Mvc","forks_url":"https://api.github.com/repos/herecydev/Mvc/forks","keys_url":"https://api.github.com/repos/herecydev/Mvc/keys{/key_id}","collaborators_url":"https://api.github.com/repos/herecydev/Mvc/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/herecydev/Mvc/teams","hooks_url":"https://api.github.com/repos/herecydev/Mvc/hooks","issue_events_url":"https://api.github.com/repos/herecydev/Mvc/issues/events{/number}","events_url":"https://api.github.com/repos/herecydev/Mvc/events","assignees_url":"https://api.github.com/repos/herecydev/Mvc/assignees{/user}","branches_url":"https://api.github.com/repos/herecydev/Mvc/branches{/branch}","tags_url":"https://api.github.com/repos/herecydev/Mvc/tags","blobs_url":"https://api.github.com/repos/herecydev/Mvc/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/herecydev/Mvc/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/herecydev/Mvc/git/refs{/sha}","trees_url":"https://api.github.com/repos/herecydev/Mvc/git/trees{/sha}","statuses_url":"https://api.github.com/repos/herecydev/Mvc/statuses/{sha}","languages_url":"https://api.github.com/repos/herecydev/Mvc/languages","stargazers_url":"https://api.github.com/repos/herecydev/Mvc/stargazers","contributors_url":"https://api.github.com/repos/herecydev/Mvc/contributors","subscribers_url":"https://api.github.com/repos/herecydev/Mvc/subscribers","subscription_url":"https://api.github.com/repos/herecydev/Mvc/subscription","commits_url":"https://api.github.com/repos/herecydev/Mvc/commits{/sha}","git_commits_url":"https://api.github.com/repos/herecydev/Mvc/git/commits{/sha}","comments_url":"https://api.github.com/repos/herecydev/Mvc/comments{/number}","issue_comment_url":"https://api.github.com/repos/herecydev/Mvc/issues/comments{/number}","contents_url":"https://api.github.com/repos/herecydev/Mvc/contents/{+path}","compare_url":"https://api.github.com/repos/herecydev/Mvc/compare/{base}...{head}","merges_url":"https://api.github.com/repos/herecydev/Mvc/merges","archive_url":"https://api.github.com/repos/herecydev/Mvc/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/herecydev/Mvc/downloads","issues_url":"https://api.github.com/repos/herecydev/Mvc/issues{/number}","pulls_url":"https://api.github.com/repos/herecydev/Mvc/pulls{/number}","milestones_url":"https://api.github.com/repos/herecydev/Mvc/milestones{/number}","notifications_url":"https://api.github.com/repos/herecydev/Mvc/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/herecydev/Mvc/labels{/name}","releases_url":"https://api.github.com/repos/herecydev/Mvc/releases{/id}","created_at":"2015-11-14T14:07:10Z","updated_at":"2015-11-14T14:07:18Z","pushed_at":"2015-11-16T17:02:42Z","git_url":"git://github.com/herecydev/Mvc.git","ssh_url":"git@github.com:herecydev/Mvc.git","clone_url":"https://github.com/herecydev/Mvc.git","svn_url":"https://github.com/herecydev/Mvc","homepage":"","size":160780,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"dev"}},"base":{"label":"aspnet:dev","ref":"dev","sha":"f6270de38748c48fed40fda895e35ebe4d08ec12","user":{"login":"aspnet","id":6476660,"avatar_url":"https://avatars.githubusercontent.com/u/6476660?v=3","gravatar_id":"","url":"https://api.github.com/users/aspnet","html_url":"https://github.com/aspnet","followers_url":"https://api.github.com/users/aspnet/followers","following_url":"https://api.github.com/users/aspnet/following{/other_user}","gists_url":"https://api.github.com/users/aspnet/gists{/gist_id}","starred_url":"https://api.github.com/users/aspnet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aspnet/subscriptions","organizations_url":"https://api.github.com/users/aspnet/orgs","repos_url":"https://api.github.com/users/aspnet/repos","events_url":"https://api.github.com/users/aspnet/events{/privacy}","received_events_url":"https://api.github.com/users/aspnet/received_events","type":"Organization","site_admin":false},"repo":{"id":15126429,"name":"Mvc","full_name":"aspnet/Mvc","owner":{"login":"aspnet","id":6476660,"avatar_url":"https://avatars.githubusercontent.com/u/6476660?v=3","gravatar_id":"","url":"https://api.github.com/users/aspnet","html_url":"https://github.com/aspnet","followers_url":"https://api.github.com/users/aspnet/followers","following_url":"https://api.github.com/users/aspnet/following{/other_user}","gists_url":"https://api.github.com/users/aspnet/gists{/gist_id}","starred_url":"https://api.github.com/users/aspnet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aspnet/subscriptions","organizations_url":"https://api.github.com/users/aspnet/orgs","repos_url":"https://api.github.com/users/aspnet/repos","events_url":"https://api.github.com/users/aspnet/events{/privacy}","received_events_url":"https://api.github.com/users/aspnet/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/aspnet/Mvc","description":"Model view controller framework for building dynamic web sites with clean separation of concerns, including the merged MVC, Web API, and Web Pages w/ Razor.","fork":false,"url":"https://api.github.com/repos/aspnet/Mvc","forks_url":"https://api.github.com/repos/aspnet/Mvc/forks","keys_url":"https://api.github.com/repos/aspnet/Mvc/keys{/key_id}","collaborators_url":"https://api.github.com/repos/aspnet/Mvc/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/aspnet/Mvc/teams","hooks_url":"https://api.github.com/repos/aspnet/Mvc/hooks","issue_events_url":"https://api.github.com/repos/aspnet/Mvc/issues/events{/number}","events_url":"https://api.github.com/repos/aspnet/Mvc/events","assignees_url":"https://api.github.com/repos/aspnet/Mvc/assignees{/user}","branches_url":"https://api.github.com/repos/aspnet/Mvc/branches{/branch}","tags_url":"https://api.github.com/repos/aspnet/Mvc/tags","blobs_url":"https://api.github.com/repos/aspnet/Mvc/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/aspnet/Mvc/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/aspnet/Mvc/git/refs{/sha}","trees_url":"https://api.github.com/repos/aspnet/Mvc/git/trees{/sha}","statuses_url":"https://api.github.com/repos/aspnet/Mvc/statuses/{sha}","languages_url":"https://api.github.com/repos/aspnet/Mvc/languages","stargazers_url":"https://api.github.com/repos/aspnet/Mvc/stargazers","contributors_url":"https://api.github.com/repos/aspnet/Mvc/contributors","subscribers_url":"https://api.github.com/repos/aspnet/Mvc/subscribers","subscription_url":"https://api.github.com/repos/aspnet/Mvc/subscription","commits_url":"https://api.github.com/repos/aspnet/Mvc/commits{/sha}","git_commits_url":"https://api.github.com/repos/aspnet/Mvc/git/commits{/sha}","comments_url":"https://api.github.com/repos/aspnet/Mvc/comments{/number}","issue_comment_url":"https://api.github.com/repos/aspnet/Mvc/issues/comments{/number}","contents_url":"https://api.github.com/repos/aspnet/Mvc/contents/{+path}","compare_url":"https://api.github.com/repos/aspnet/Mvc/compare/{base}...{head}","merges_url":"https://api.github.com/repos/aspnet/Mvc/merges","archive_url":"https://api.github.com/repos/aspnet/Mvc/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/aspnet/Mvc/downloads","issues_url":"https://api.github.com/repos/aspnet/Mvc/issues{/number}","pulls_url":"https://api.github.com/repos/aspnet/Mvc/pulls{/number}","milestones_url":"https://api.github.com/repos/aspnet/Mvc/milestones{/number}","notifications_url":"https://api.github.com/repos/aspnet/Mvc/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/aspnet/Mvc/labels{/name}","releases_url":"https://api.github.com/repos/aspnet/Mvc/releases{/id}","created_at":"2013-12-12T03:54:00Z","updated_at":"2015-11-16T07:07:51Z","pushed_at":"2015-11-16T17:49:44Z","git_url":"git://github.com/aspnet/Mvc.git","ssh_url":"git@github.com:aspnet/Mvc.git","clone_url":"https://github.com/aspnet/Mvc.git","svn_url":"https://github.com/aspnet/Mvc","homepage":"","size":24808,"stargazers_count":2381,"watchers_count":2381,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":921,"mirror_url":null,"open_issues_count":266,"forks":921,"open_issues":266,"watchers":2381,"default_branch":"dev"}},"_links":{"self":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/3559"},"html":{"href":"https://github.com/aspnet/Mvc/pull/3559"},"issue":{"href":"https://api.github.com/repos/aspnet/Mvc/issues/3559"},"comments":{"href":"https://api.github.com/repos/aspnet/Mvc/issues/3559/comments"},"review_comments":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/3559/comments"},"review_comment":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/aspnet/Mvc/pulls/3559/commits"},"statuses":{"href":"https://api.github.com/repos/aspnet/Mvc/statuses/b4b9693aa0942804f9e9b4bddf18f7043129b222"}}}}