{"action":"created","comment":{"url":"https://api.github.com/repos/rspec/rspec-expectations/pulls/comments/28195718","id":28195718,"diff_hunk":"@@ -46,7 +46,12 @@ def failure_message_when_negated\n         # @api private\n         # @return [Boolean]\n         def diffable?\n-          true\n+          return true unless actual.is_a?(String) && expected.is_a?(Array)\n+\n+          lines = actual.split(\"\\n\")\n+          expected.none? do |str|\n+            actual.include?(str) && lines.none? { |line| line == str }\n+          end","path":"lib/rspec/matchers/built_in/include.rb","position":10,"original_position":10,"commit_id":"17b49ff6a5f2946006a5a47d2cb86c4d3d4fbf7e","original_commit_id":"17b49ff6a5f2946006a5a47d2cb86c4d3d4fbf7e","user":{"login":"imtayadeway","id":1710874,"avatar_url":"https://avatars.githubusercontent.com/u/1710874?v=3","gravatar_id":"","url":"https://api.github.com/users/imtayadeway","html_url":"https://github.com/imtayadeway","followers_url":"https://api.github.com/users/imtayadeway/followers","following_url":"https://api.github.com/users/imtayadeway/following{/other_user}","gists_url":"https://api.github.com/users/imtayadeway/gists{/gist_id}","starred_url":"https://api.github.com/users/imtayadeway/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/imtayadeway/subscriptions","organizations_url":"https://api.github.com/users/imtayadeway/orgs","repos_url":"https://api.github.com/users/imtayadeway/repos","events_url":"https://api.github.com/users/imtayadeway/events{/privacy}","received_events_url":"https://api.github.com/users/imtayadeway/received_events","type":"User","site_admin":false},"body":"Great suggestion!","created_at":"2015-04-11T15:20:20Z","updated_at":"2015-04-11T15:20:20Z","html_url":"https://github.com/rspec/rspec-expectations/pull/763#discussion_r28195718","pull_request_url":"https://api.github.com/repos/rspec/rspec-expectations/pulls/763","_links":{"self":{"href":"https://api.github.com/repos/rspec/rspec-expectations/pulls/comments/28195718"},"html":{"href":"https://github.com/rspec/rspec-expectations/pull/763#discussion_r28195718"},"pull_request":{"href":"https://api.github.com/repos/rspec/rspec-expectations/pulls/763"}}},"pull_request":{"url":"https://api.github.com/repos/rspec/rspec-expectations/pulls/763","id":33097110,"html_url":"https://github.com/rspec/rspec-expectations/pull/763","diff_url":"https://github.com/rspec/rspec-expectations/pull/763.diff","patch_url":"https://github.com/rspec/rspec-expectations/pull/763.patch","issue_url":"https://api.github.com/repos/rspec/rspec-expectations/issues/763","number":763,"state":"open","locked":false,"title":"Avoid diffing for problematic `include` cases","user":{"login":"imtayadeway","id":1710874,"avatar_url":"https://avatars.githubusercontent.com/u/1710874?v=3","gravatar_id":"","url":"https://api.github.com/users/imtayadeway","html_url":"https://github.com/imtayadeway","followers_url":"https://api.github.com/users/imtayadeway/followers","following_url":"https://api.github.com/users/imtayadeway/following{/other_user}","gists_url":"https://api.github.com/users/imtayadeway/gists{/gist_id}","starred_url":"https://api.github.com/users/imtayadeway/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/imtayadeway/subscriptions","organizations_url":"https://api.github.com/users/imtayadeway/orgs","repos_url":"https://api.github.com/users/imtayadeway/repos","events_url":"https://api.github.com/users/imtayadeway/events{/privacy}","received_events_url":"https://api.github.com/users/imtayadeway/received_events","type":"User","site_admin":false},"body":"Avoid diffing for problematic include cases.\r\n    \r\nInclude#diffable? will return true unless it detects a multiline string with at least one \"expected\" that is included in \"actual\", but is not an exact match for any single line.\r\n\r\nThis was the most conservative strategy I could think of on this pass, and to my amazement it didn't cause any other tests to fail. (!)\r\n\r\nI can squash these commits once this PR is ready, but didn't want to lose my first commit in case I needed that test again. It was by far the hardest part of the task so far!\r\n\r\nAddresses https://github.com/rspec/rspec-expectations/issues/746","created_at":"2015-04-11T03:46:18Z","updated_at":"2015-04-11T15:20:20Z","closed_at":null,"merged_at":null,"merge_commit_sha":"b51e8f58aecd35ab3388bf736b9b48e3c8628616","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/rspec/rspec-expectations/pulls/763/commits","review_comments_url":"https://api.github.com/repos/rspec/rspec-expectations/pulls/763/comments","review_comment_url":"https://api.github.com/repos/rspec/rspec-expectations/pulls/comments{/number}","comments_url":"https://api.github.com/repos/rspec/rspec-expectations/issues/763/comments","statuses_url":"https://api.github.com/repos/rspec/rspec-expectations/statuses/17b49ff6a5f2946006a5a47d2cb86c4d3d4fbf7e","head":{"label":"imtayadeway:tw/diff-substrings","ref":"tw/diff-substrings","sha":"17b49ff6a5f2946006a5a47d2cb86c4d3d4fbf7e","user":{"login":"imtayadeway","id":1710874,"avatar_url":"https://avatars.githubusercontent.com/u/1710874?v=3","gravatar_id":"","url":"https://api.github.com/users/imtayadeway","html_url":"https://github.com/imtayadeway","followers_url":"https://api.github.com/users/imtayadeway/followers","following_url":"https://api.github.com/users/imtayadeway/following{/other_user}","gists_url":"https://api.github.com/users/imtayadeway/gists{/gist_id}","starred_url":"https://api.github.com/users/imtayadeway/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/imtayadeway/subscriptions","organizations_url":"https://api.github.com/users/imtayadeway/orgs","repos_url":"https://api.github.com/users/imtayadeway/repos","events_url":"https://api.github.com/users/imtayadeway/events{/privacy}","received_events_url":"https://api.github.com/users/imtayadeway/received_events","type":"User","site_admin":false},"repo":{"id":31226871,"name":"rspec-expectations","full_name":"imtayadeway/rspec-expectations","owner":{"login":"imtayadeway","id":1710874,"avatar_url":"https://avatars.githubusercontent.com/u/1710874?v=3","gravatar_id":"","url":"https://api.github.com/users/imtayadeway","html_url":"https://github.com/imtayadeway","followers_url":"https://api.github.com/users/imtayadeway/followers","following_url":"https://api.github.com/users/imtayadeway/following{/other_user}","gists_url":"https://api.github.com/users/imtayadeway/gists{/gist_id}","starred_url":"https://api.github.com/users/imtayadeway/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/imtayadeway/subscriptions","organizations_url":"https://api.github.com/users/imtayadeway/orgs","repos_url":"https://api.github.com/users/imtayadeway/repos","events_url":"https://api.github.com/users/imtayadeway/events{/privacy}","received_events_url":"https://api.github.com/users/imtayadeway/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/imtayadeway/rspec-expectations","description":"Provides a readable API to express expected outcomes of a code example","fork":true,"url":"https://api.github.com/repos/imtayadeway/rspec-expectations","forks_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/forks","keys_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/keys{/key_id}","collaborators_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/teams","hooks_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/hooks","issue_events_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/issues/events{/number}","events_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/events","assignees_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/assignees{/user}","branches_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/branches{/branch}","tags_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/tags","blobs_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/git/refs{/sha}","trees_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/git/trees{/sha}","statuses_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/statuses/{sha}","languages_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/languages","stargazers_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/stargazers","contributors_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/contributors","subscribers_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/subscribers","subscription_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/subscription","commits_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/commits{/sha}","git_commits_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/git/commits{/sha}","comments_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/comments{/number}","issue_comment_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/issues/comments{/number}","contents_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/contents/{+path}","compare_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/compare/{base}...{head}","merges_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/merges","archive_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/downloads","issues_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/issues{/number}","pulls_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/pulls{/number}","milestones_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/milestones{/number}","notifications_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/labels{/name}","releases_url":"https://api.github.com/repos/imtayadeway/rspec-expectations/releases{/id}","created_at":"2015-02-23T20:02:56Z","updated_at":"2015-02-26T02:05:17Z","pushed_at":"2015-04-11T03:37:17Z","git_url":"git://github.com/imtayadeway/rspec-expectations.git","ssh_url":"git@github.com:imtayadeway/rspec-expectations.git","clone_url":"https://github.com/imtayadeway/rspec-expectations.git","svn_url":"https://github.com/imtayadeway/rspec-expectations","homepage":"http://relishapp.com/rspec/rspec-expectations","size":4247,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"rspec:master","ref":"master","sha":"f0b79d1e58bcc209191bfc99a04211dd38718955","user":{"login":"rspec","id":22388,"avatar_url":"https://avatars.githubusercontent.com/u/22388?v=3","gravatar_id":"","url":"https://api.github.com/users/rspec","html_url":"https://github.com/rspec","followers_url":"https://api.github.com/users/rspec/followers","following_url":"https://api.github.com/users/rspec/following{/other_user}","gists_url":"https://api.github.com/users/rspec/gists{/gist_id}","starred_url":"https://api.github.com/users/rspec/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rspec/subscriptions","organizations_url":"https://api.github.com/users/rspec/orgs","repos_url":"https://api.github.com/users/rspec/repos","events_url":"https://api.github.com/users/rspec/events{/privacy}","received_events_url":"https://api.github.com/users/rspec/received_events","type":"Organization","site_admin":false},"repo":{"id":238986,"name":"rspec-expectations","full_name":"rspec/rspec-expectations","owner":{"login":"rspec","id":22388,"avatar_url":"https://avatars.githubusercontent.com/u/22388?v=3","gravatar_id":"","url":"https://api.github.com/users/rspec","html_url":"https://github.com/rspec","followers_url":"https://api.github.com/users/rspec/followers","following_url":"https://api.github.com/users/rspec/following{/other_user}","gists_url":"https://api.github.com/users/rspec/gists{/gist_id}","starred_url":"https://api.github.com/users/rspec/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rspec/subscriptions","organizations_url":"https://api.github.com/users/rspec/orgs","repos_url":"https://api.github.com/users/rspec/repos","events_url":"https://api.github.com/users/rspec/events{/privacy}","received_events_url":"https://api.github.com/users/rspec/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/rspec/rspec-expectations","description":"Provides a readable API to express expected outcomes of a code example","fork":false,"url":"https://api.github.com/repos/rspec/rspec-expectations","forks_url":"https://api.github.com/repos/rspec/rspec-expectations/forks","keys_url":"https://api.github.com/repos/rspec/rspec-expectations/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rspec/rspec-expectations/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rspec/rspec-expectations/teams","hooks_url":"https://api.github.com/repos/rspec/rspec-expectations/hooks","issue_events_url":"https://api.github.com/repos/rspec/rspec-expectations/issues/events{/number}","events_url":"https://api.github.com/repos/rspec/rspec-expectations/events","assignees_url":"https://api.github.com/repos/rspec/rspec-expectations/assignees{/user}","branches_url":"https://api.github.com/repos/rspec/rspec-expectations/branches{/branch}","tags_url":"https://api.github.com/repos/rspec/rspec-expectations/tags","blobs_url":"https://api.github.com/repos/rspec/rspec-expectations/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rspec/rspec-expectations/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rspec/rspec-expectations/git/refs{/sha}","trees_url":"https://api.github.com/repos/rspec/rspec-expectations/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rspec/rspec-expectations/statuses/{sha}","languages_url":"https://api.github.com/repos/rspec/rspec-expectations/languages","stargazers_url":"https://api.github.com/repos/rspec/rspec-expectations/stargazers","contributors_url":"https://api.github.com/repos/rspec/rspec-expectations/contributors","subscribers_url":"https://api.github.com/repos/rspec/rspec-expectations/subscribers","subscription_url":"https://api.github.com/repos/rspec/rspec-expectations/subscription","commits_url":"https://api.github.com/repos/rspec/rspec-expectations/commits{/sha}","git_commits_url":"https://api.github.com/repos/rspec/rspec-expectations/git/commits{/sha}","comments_url":"https://api.github.com/repos/rspec/rspec-expectations/comments{/number}","issue_comment_url":"https://api.github.com/repos/rspec/rspec-expectations/issues/comments{/number}","contents_url":"https://api.github.com/repos/rspec/rspec-expectations/contents/{+path}","compare_url":"https://api.github.com/repos/rspec/rspec-expectations/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rspec/rspec-expectations/merges","archive_url":"https://api.github.com/repos/rspec/rspec-expectations/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rspec/rspec-expectations/downloads","issues_url":"https://api.github.com/repos/rspec/rspec-expectations/issues{/number}","pulls_url":"https://api.github.com/repos/rspec/rspec-expectations/pulls{/number}","milestones_url":"https://api.github.com/repos/rspec/rspec-expectations/milestones{/number}","notifications_url":"https://api.github.com/repos/rspec/rspec-expectations/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rspec/rspec-expectations/labels{/name}","releases_url":"https://api.github.com/repos/rspec/rspec-expectations/releases{/id}","created_at":"2009-06-29T15:58:17Z","updated_at":"2015-04-08T14:38:53Z","pushed_at":"2015-04-11T03:46:18Z","git_url":"git://github.com/rspec/rspec-expectations.git","ssh_url":"git@github.com:rspec/rspec-expectations.git","clone_url":"https://github.com/rspec/rspec-expectations.git","svn_url":"https://github.com/rspec/rspec-expectations","homepage":"http://relishapp.com/rspec/rspec-expectations","size":9542,"stargazers_count":615,"watchers_count":615,"language":"Ruby","has_issues":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":202,"mirror_url":null,"open_issues_count":26,"forks":202,"open_issues":26,"watchers":615,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/rspec/rspec-expectations/pulls/763"},"html":{"href":"https://github.com/rspec/rspec-expectations/pull/763"},"issue":{"href":"https://api.github.com/repos/rspec/rspec-expectations/issues/763"},"comments":{"href":"https://api.github.com/repos/rspec/rspec-expectations/issues/763/comments"},"review_comments":{"href":"https://api.github.com/repos/rspec/rspec-expectations/pulls/763/comments"},"review_comment":{"href":"https://api.github.com/repos/rspec/rspec-expectations/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/rspec/rspec-expectations/pulls/763/commits"},"statuses":{"href":"https://api.github.com/repos/rspec/rspec-expectations/statuses/17b49ff6a5f2946006a5a47d2cb86c4d3d4fbf7e"}}}}