{"action":"created","comment":{"url":"https://api.github.com/repos/troessner/reek/pulls/comments/40908484","id":40908484,"diff_hunk":"@@ -53,12 +55,17 @@ def matches_smell_type?(klass)\n         smell_classes.include?(klass.to_s)\n       end\n \n-      def matches_smell_details?(other_smell_details = {})\n-        common_parameters_equal?(other_smell_details)\n+      def matches_attributes?(other_attributes = {})\n+        check_attributes_comparability(other_attributes)\n+        return false unless common_parameters_equal?(other_attributes[:parameters])\n+        other_attributes.delete(:parameters)\n+        other_attributes.all? do |other_key, other_value|\n+          send(other_key) == other_value\n+        end\n       end\n \n-      def matches?(klass, other_smell_details = {})\n-        matches_smell_type?(klass) && matches_smell_details?(other_smell_details)","path":"lib/reek/smells/smell_warning.rb","position":25,"original_position":25,"commit_id":"eb630920c72034e5724cf75e7261f292af85cd02","original_commit_id":"eb630920c72034e5724cf75e7261f292af85cd02","user":{"login":"troessner","id":271109,"avatar_url":"https://avatars.githubusercontent.com/u/271109?v=3","gravatar_id":"","url":"https://api.github.com/users/troessner","html_url":"https://github.com/troessner","followers_url":"https://api.github.com/users/troessner/followers","following_url":"https://api.github.com/users/troessner/following{/other_user}","gists_url":"https://api.github.com/users/troessner/gists{/gist_id}","starred_url":"https://api.github.com/users/troessner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/troessner/subscriptions","organizations_url":"https://api.github.com/users/troessner/orgs","repos_url":"https://api.github.com/users/troessner/repos","events_url":"https://api.github.com/users/troessner/events{/privacy}","received_events_url":"https://api.github.com/users/troessner/received_events","type":"User","site_admin":false},"body":"Let's also rename that to \"attributes\" here and below.","created_at":"2015-10-01T12:45:48Z","updated_at":"2015-10-01T12:45:48Z","html_url":"https://github.com/troessner/reek/pull/732#discussion_r40908484","pull_request_url":"https://api.github.com/repos/troessner/reek/pulls/732","_links":{"self":{"href":"https://api.github.com/repos/troessner/reek/pulls/comments/40908484"},"html":{"href":"https://github.com/troessner/reek/pull/732#discussion_r40908484"},"pull_request":{"href":"https://api.github.com/repos/troessner/reek/pulls/732"}}},"pull_request":{"url":"https://api.github.com/repos/troessner/reek/pulls/732","id":46244183,"html_url":"https://github.com/troessner/reek/pull/732","diff_url":"https://github.com/troessner/reek/pull/732.diff","patch_url":"https://github.com/troessner/reek/pull/732.patch","issue_url":"https://api.github.com/repos/troessner/reek/issues/732","number":732,"state":"open","locked":false,"title":"adding ability to check for smell message contents","user":{"login":"tansaku","id":30216,"avatar_url":"https://avatars.githubusercontent.com/u/30216?v=3","gravatar_id":"","url":"https://api.github.com/users/tansaku","html_url":"https://github.com/tansaku","followers_url":"https://api.github.com/users/tansaku/followers","following_url":"https://api.github.com/users/tansaku/following{/other_user}","gists_url":"https://api.github.com/users/tansaku/gists{/gist_id}","starred_url":"https://api.github.com/users/tansaku/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tansaku/subscriptions","organizations_url":"https://api.github.com/users/tansaku/orgs","repos_url":"https://api.github.com/users/tansaku/repos","events_url":"https://api.github.com/users/tansaku/events{/privacy}","received_events_url":"https://api.github.com/users/tansaku/received_events","type":"User","site_admin":false},"body":"So this is another tiny step towards https://github.com/troessner/reek/issues/589 getting set up so that we can actually test that a smell message has changed","created_at":"2015-09-29T07:26:53Z","updated_at":"2015-10-01T12:45:48Z","closed_at":null,"merged_at":null,"merge_commit_sha":"3cdbc37a84b92ccadde5d1e68cbae316629ed4a7","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/troessner/reek/pulls/732/commits","review_comments_url":"https://api.github.com/repos/troessner/reek/pulls/732/comments","review_comment_url":"https://api.github.com/repos/troessner/reek/pulls/comments{/number}","comments_url":"https://api.github.com/repos/troessner/reek/issues/732/comments","statuses_url":"https://api.github.com/repos/troessner/reek/statuses/eb630920c72034e5724cf75e7261f292af85cd02","head":{"label":"tansaku:589-customizing-smell-messages","ref":"589-customizing-smell-messages","sha":"eb630920c72034e5724cf75e7261f292af85cd02","user":{"login":"tansaku","id":30216,"avatar_url":"https://avatars.githubusercontent.com/u/30216?v=3","gravatar_id":"","url":"https://api.github.com/users/tansaku","html_url":"https://github.com/tansaku","followers_url":"https://api.github.com/users/tansaku/followers","following_url":"https://api.github.com/users/tansaku/following{/other_user}","gists_url":"https://api.github.com/users/tansaku/gists{/gist_id}","starred_url":"https://api.github.com/users/tansaku/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tansaku/subscriptions","organizations_url":"https://api.github.com/users/tansaku/orgs","repos_url":"https://api.github.com/users/tansaku/repos","events_url":"https://api.github.com/users/tansaku/events{/privacy}","received_events_url":"https://api.github.com/users/tansaku/received_events","type":"User","site_admin":false},"repo":{"id":41346347,"name":"reek","full_name":"tansaku/reek","owner":{"login":"tansaku","id":30216,"avatar_url":"https://avatars.githubusercontent.com/u/30216?v=3","gravatar_id":"","url":"https://api.github.com/users/tansaku","html_url":"https://github.com/tansaku","followers_url":"https://api.github.com/users/tansaku/followers","following_url":"https://api.github.com/users/tansaku/following{/other_user}","gists_url":"https://api.github.com/users/tansaku/gists{/gist_id}","starred_url":"https://api.github.com/users/tansaku/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tansaku/subscriptions","organizations_url":"https://api.github.com/users/tansaku/orgs","repos_url":"https://api.github.com/users/tansaku/repos","events_url":"https://api.github.com/users/tansaku/events{/privacy}","received_events_url":"https://api.github.com/users/tansaku/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/tansaku/reek","description":"Code smell detector for Ruby","fork":true,"url":"https://api.github.com/repos/tansaku/reek","forks_url":"https://api.github.com/repos/tansaku/reek/forks","keys_url":"https://api.github.com/repos/tansaku/reek/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tansaku/reek/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tansaku/reek/teams","hooks_url":"https://api.github.com/repos/tansaku/reek/hooks","issue_events_url":"https://api.github.com/repos/tansaku/reek/issues/events{/number}","events_url":"https://api.github.com/repos/tansaku/reek/events","assignees_url":"https://api.github.com/repos/tansaku/reek/assignees{/user}","branches_url":"https://api.github.com/repos/tansaku/reek/branches{/branch}","tags_url":"https://api.github.com/repos/tansaku/reek/tags","blobs_url":"https://api.github.com/repos/tansaku/reek/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tansaku/reek/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tansaku/reek/git/refs{/sha}","trees_url":"https://api.github.com/repos/tansaku/reek/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tansaku/reek/statuses/{sha}","languages_url":"https://api.github.com/repos/tansaku/reek/languages","stargazers_url":"https://api.github.com/repos/tansaku/reek/stargazers","contributors_url":"https://api.github.com/repos/tansaku/reek/contributors","subscribers_url":"https://api.github.com/repos/tansaku/reek/subscribers","subscription_url":"https://api.github.com/repos/tansaku/reek/subscription","commits_url":"https://api.github.com/repos/tansaku/reek/commits{/sha}","git_commits_url":"https://api.github.com/repos/tansaku/reek/git/commits{/sha}","comments_url":"https://api.github.com/repos/tansaku/reek/comments{/number}","issue_comment_url":"https://api.github.com/repos/tansaku/reek/issues/comments{/number}","contents_url":"https://api.github.com/repos/tansaku/reek/contents/{+path}","compare_url":"https://api.github.com/repos/tansaku/reek/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tansaku/reek/merges","archive_url":"https://api.github.com/repos/tansaku/reek/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tansaku/reek/downloads","issues_url":"https://api.github.com/repos/tansaku/reek/issues{/number}","pulls_url":"https://api.github.com/repos/tansaku/reek/pulls{/number}","milestones_url":"https://api.github.com/repos/tansaku/reek/milestones{/number}","notifications_url":"https://api.github.com/repos/tansaku/reek/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tansaku/reek/labels{/name}","releases_url":"https://api.github.com/repos/tansaku/reek/releases{/id}","created_at":"2015-08-25T06:13:14Z","updated_at":"2015-08-25T06:13:15Z","pushed_at":"2015-10-01T09:38:05Z","git_url":"git://github.com/tansaku/reek.git","ssh_url":"git@github.com:tansaku/reek.git","clone_url":"https://github.com/tansaku/reek.git","svn_url":"https://github.com/tansaku/reek","homepage":"https://github.com/troessner/reek/wiki","size":3937,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_downloads":true,"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":"troessner:master","ref":"master","sha":"e530f8111183014254614bb573122b1ae6435fab","user":{"login":"troessner","id":271109,"avatar_url":"https://avatars.githubusercontent.com/u/271109?v=3","gravatar_id":"","url":"https://api.github.com/users/troessner","html_url":"https://github.com/troessner","followers_url":"https://api.github.com/users/troessner/followers","following_url":"https://api.github.com/users/troessner/following{/other_user}","gists_url":"https://api.github.com/users/troessner/gists{/gist_id}","starred_url":"https://api.github.com/users/troessner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/troessner/subscriptions","organizations_url":"https://api.github.com/users/troessner/orgs","repos_url":"https://api.github.com/users/troessner/repos","events_url":"https://api.github.com/users/troessner/events{/privacy}","received_events_url":"https://api.github.com/users/troessner/received_events","type":"User","site_admin":false},"repo":{"id":49515,"name":"reek","full_name":"troessner/reek","owner":{"login":"troessner","id":271109,"avatar_url":"https://avatars.githubusercontent.com/u/271109?v=3","gravatar_id":"","url":"https://api.github.com/users/troessner","html_url":"https://github.com/troessner","followers_url":"https://api.github.com/users/troessner/followers","following_url":"https://api.github.com/users/troessner/following{/other_user}","gists_url":"https://api.github.com/users/troessner/gists{/gist_id}","starred_url":"https://api.github.com/users/troessner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/troessner/subscriptions","organizations_url":"https://api.github.com/users/troessner/orgs","repos_url":"https://api.github.com/users/troessner/repos","events_url":"https://api.github.com/users/troessner/events{/privacy}","received_events_url":"https://api.github.com/users/troessner/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/troessner/reek","description":"Code smell detector for Ruby","fork":false,"url":"https://api.github.com/repos/troessner/reek","forks_url":"https://api.github.com/repos/troessner/reek/forks","keys_url":"https://api.github.com/repos/troessner/reek/keys{/key_id}","collaborators_url":"https://api.github.com/repos/troessner/reek/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/troessner/reek/teams","hooks_url":"https://api.github.com/repos/troessner/reek/hooks","issue_events_url":"https://api.github.com/repos/troessner/reek/issues/events{/number}","events_url":"https://api.github.com/repos/troessner/reek/events","assignees_url":"https://api.github.com/repos/troessner/reek/assignees{/user}","branches_url":"https://api.github.com/repos/troessner/reek/branches{/branch}","tags_url":"https://api.github.com/repos/troessner/reek/tags","blobs_url":"https://api.github.com/repos/troessner/reek/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/troessner/reek/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/troessner/reek/git/refs{/sha}","trees_url":"https://api.github.com/repos/troessner/reek/git/trees{/sha}","statuses_url":"https://api.github.com/repos/troessner/reek/statuses/{sha}","languages_url":"https://api.github.com/repos/troessner/reek/languages","stargazers_url":"https://api.github.com/repos/troessner/reek/stargazers","contributors_url":"https://api.github.com/repos/troessner/reek/contributors","subscribers_url":"https://api.github.com/repos/troessner/reek/subscribers","subscription_url":"https://api.github.com/repos/troessner/reek/subscription","commits_url":"https://api.github.com/repos/troessner/reek/commits{/sha}","git_commits_url":"https://api.github.com/repos/troessner/reek/git/commits{/sha}","comments_url":"https://api.github.com/repos/troessner/reek/comments{/number}","issue_comment_url":"https://api.github.com/repos/troessner/reek/issues/comments{/number}","contents_url":"https://api.github.com/repos/troessner/reek/contents/{+path}","compare_url":"https://api.github.com/repos/troessner/reek/compare/{base}...{head}","merges_url":"https://api.github.com/repos/troessner/reek/merges","archive_url":"https://api.github.com/repos/troessner/reek/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/troessner/reek/downloads","issues_url":"https://api.github.com/repos/troessner/reek/issues{/number}","pulls_url":"https://api.github.com/repos/troessner/reek/pulls{/number}","milestones_url":"https://api.github.com/repos/troessner/reek/milestones{/number}","notifications_url":"https://api.github.com/repos/troessner/reek/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/troessner/reek/labels{/name}","releases_url":"https://api.github.com/repos/troessner/reek/releases{/id}","created_at":"2008-09-05T10:48:33Z","updated_at":"2015-09-30T14:16:53Z","pushed_at":"2015-10-01T09:38:05Z","git_url":"git://github.com/troessner/reek.git","ssh_url":"git@github.com:troessner/reek.git","clone_url":"https://github.com/troessner/reek.git","svn_url":"https://github.com/troessner/reek","homepage":"https://github.com/troessner/reek/wiki","size":8963,"stargazers_count":1531,"watchers_count":1531,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":103,"mirror_url":null,"open_issues_count":30,"forks":103,"open_issues":30,"watchers":1531,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/troessner/reek/pulls/732"},"html":{"href":"https://github.com/troessner/reek/pull/732"},"issue":{"href":"https://api.github.com/repos/troessner/reek/issues/732"},"comments":{"href":"https://api.github.com/repos/troessner/reek/issues/732/comments"},"review_comments":{"href":"https://api.github.com/repos/troessner/reek/pulls/732/comments"},"review_comment":{"href":"https://api.github.com/repos/troessner/reek/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/troessner/reek/pulls/732/commits"},"statuses":{"href":"https://api.github.com/repos/troessner/reek/statuses/eb630920c72034e5724cf75e7261f292af85cd02"}}}}