{"action":"created","comment":{"url":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/comments/188531152","pull_request_review_id":120526080,"id":188531152,"diff_hunk":"@@ -176,36 +176,32 @@ def no_state_change_only_empty_event\n       \n         it \"should set the old_value on the event\" do\n           dirty_object.change_name \"new_name\"\n-          expect(dirty_object.aggregate_events.last[:event_data][:attribute_deltas].first[:old_value]).to eql \"old_value\"\n+          expect(dirty_object.aggregate_events.last[:event_data][\"name\"][:old_value]).to eql \"old_value\"\n         end\n \n         it \"should not change aggregate_id\" do\n           dirty_object.change_name \"new_name\"\n-          expect(dirty_object.aggregate_events.last[:event_data][:attribute_deltas].last[:attribute_name]).not_to eql \"aggregate_id\"\n+          expect(dirty_object.aggregate_events.last[:event_data][\"attribute_name\"]).not_to eql \"aggregate_id\"\n         end\n \n         it \"should not change sex attribute if sex method is not runned\" do\n           dirty_object.change_name \"new_name\"\n           dirty_object.aggregate_events.each do |event|\n-            event[:event_data][:attribute_deltas].each do |attribute_delta|\n-              expect(attribute_delta[:attribute_name]).not_to eql \"sex\"\n-            end\n+            expect(event[:event_data][\"sex\"].nil?).to be_truthy\n           end\n         end\n \n         it \"should not change sex attribute if sex attribute is the same\" do\n           dirty_object.change_sex \"hen\"\n           dirty_object.aggregate_events.each do |event|\n-            event[:event_data][:attribute_deltas].each do |attribute_delta|\n-              expect(attribute_delta[:attribute_name]).not_to eql \"sex\"\n-            end\n+            expect(event[:event_data][\"sex\"].nil?).to be_truthy\n           end\n         end\n \n         it \"should set old_value and new_value on sex change\" do\n           dirty_object.change_sex \"shemale\"\n-          expect(dirty_object.aggregate_events.last[:event_data][:attribute_deltas].first[:old_value]).to eql \"hen\"\n-          expect(dirty_object.aggregate_events.last[:event_data][:attribute_deltas].first[:new_value]).to eql \"shemale\"\n+          expect(dirty_object.aggregate_events.last[:event_data][\"sex\"][:old_value]).to eql \"hen\"","path":"spec/aggregate_root_spec.rb","position":47,"original_position":47,"commit_id":"898f44a41d7b063c21e064e182e618a24d17afcd","original_commit_id":"898f44a41d7b063c21e064e182e618a24d17afcd","user":{"login":"hallgren","id":428524,"avatar_url":"https://avatars2.githubusercontent.com/u/428524?v=4","gravatar_id":"","url":"https://api.github.com/users/hallgren","html_url":"https://github.com/hallgren","followers_url":"https://api.github.com/users/hallgren/followers","following_url":"https://api.github.com/users/hallgren/following{/other_user}","gists_url":"https://api.github.com/users/hallgren/gists{/gist_id}","starred_url":"https://api.github.com/users/hallgren/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hallgren/subscriptions","organizations_url":"https://api.github.com/users/hallgren/orgs","repos_url":"https://api.github.com/users/hallgren/repos","events_url":"https://api.github.com/users/hallgren/events{/privacy}","received_events_url":"https://api.github.com/users/hallgren/received_events","type":"User","site_admin":false},"body":":+1: \r\n","created_at":"2018-05-16T07:49:35Z","updated_at":"2018-05-16T07:49:35Z","html_url":"https://github.com/Sandthorn/sandthorn/pull/56#discussion_r188531152","pull_request_url":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/56","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/comments/188531152"},"html":{"href":"https://github.com/Sandthorn/sandthorn/pull/56#discussion_r188531152"},"pull_request":{"href":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/56"}},"in_reply_to_id":188251233},"pull_request":{"url":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/56","id":184880647,"html_url":"https://github.com/Sandthorn/sandthorn/pull/56","diff_url":"https://github.com/Sandthorn/sandthorn/pull/56.diff","patch_url":"https://github.com/Sandthorn/sandthorn/pull/56.patch","issue_url":"https://api.github.com/repos/Sandthorn/sandthorn/issues/56","number":56,"state":"open","locked":false,"title":"replace attibute_deltas array with hash","user":{"login":"hallgren","id":428524,"avatar_url":"https://avatars2.githubusercontent.com/u/428524?v=4","gravatar_id":"","url":"https://api.github.com/users/hallgren","html_url":"https://github.com/hallgren","followers_url":"https://api.github.com/users/hallgren/followers","following_url":"https://api.github.com/users/hallgren/following{/other_user}","gists_url":"https://api.github.com/users/hallgren/gists{/gist_id}","starred_url":"https://api.github.com/users/hallgren/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hallgren/subscriptions","organizations_url":"https://api.github.com/users/hallgren/orgs","repos_url":"https://api.github.com/users/hallgren/repos","events_url":"https://api.github.com/users/hallgren/events{/privacy}","received_events_url":"https://api.github.com/users/hallgren/received_events","type":"User","site_admin":false},"body":"replace the attribute_deltas array with hash where the `key` is the attribut_name and `value` old_value and new_value\r\n\r\nOne question remains and that´s if the keys should be strings or symbols?","created_at":"2018-04-30T05:21:11Z","updated_at":"2018-05-16T07:49:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"2f15a0050aedbcf2fbd6ecb572b5f18f7cbbb959","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/56/commits","review_comments_url":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/56/comments","review_comment_url":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Sandthorn/sandthorn/issues/56/comments","statuses_url":"https://api.github.com/repos/Sandthorn/sandthorn/statuses/898f44a41d7b063c21e064e182e618a24d17afcd","head":{"label":"Sandthorn:remove_attribute_deltas_from_event","ref":"remove_attribute_deltas_from_event","sha":"898f44a41d7b063c21e064e182e618a24d17afcd","user":{"login":"Sandthorn","id":5220194,"avatar_url":"https://avatars2.githubusercontent.com/u/5220194?v=4","gravatar_id":"","url":"https://api.github.com/users/Sandthorn","html_url":"https://github.com/Sandthorn","followers_url":"https://api.github.com/users/Sandthorn/followers","following_url":"https://api.github.com/users/Sandthorn/following{/other_user}","gists_url":"https://api.github.com/users/Sandthorn/gists{/gist_id}","starred_url":"https://api.github.com/users/Sandthorn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sandthorn/subscriptions","organizations_url":"https://api.github.com/users/Sandthorn/orgs","repos_url":"https://api.github.com/users/Sandthorn/repos","events_url":"https://api.github.com/users/Sandthorn/events{/privacy}","received_events_url":"https://api.github.com/users/Sandthorn/received_events","type":"Organization","site_admin":false},"repo":{"id":12103058,"name":"sandthorn","full_name":"Sandthorn/sandthorn","owner":{"login":"Sandthorn","id":5220194,"avatar_url":"https://avatars2.githubusercontent.com/u/5220194?v=4","gravatar_id":"","url":"https://api.github.com/users/Sandthorn","html_url":"https://github.com/Sandthorn","followers_url":"https://api.github.com/users/Sandthorn/followers","following_url":"https://api.github.com/users/Sandthorn/following{/other_user}","gists_url":"https://api.github.com/users/Sandthorn/gists{/gist_id}","starred_url":"https://api.github.com/users/Sandthorn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sandthorn/subscriptions","organizations_url":"https://api.github.com/users/Sandthorn/orgs","repos_url":"https://api.github.com/users/Sandthorn/repos","events_url":"https://api.github.com/users/Sandthorn/events{/privacy}","received_events_url":"https://api.github.com/users/Sandthorn/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Sandthorn/sandthorn","description":"Main gem for Sandthorn","fork":false,"url":"https://api.github.com/repos/Sandthorn/sandthorn","forks_url":"https://api.github.com/repos/Sandthorn/sandthorn/forks","keys_url":"https://api.github.com/repos/Sandthorn/sandthorn/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Sandthorn/sandthorn/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Sandthorn/sandthorn/teams","hooks_url":"https://api.github.com/repos/Sandthorn/sandthorn/hooks","issue_events_url":"https://api.github.com/repos/Sandthorn/sandthorn/issues/events{/number}","events_url":"https://api.github.com/repos/Sandthorn/sandthorn/events","assignees_url":"https://api.github.com/repos/Sandthorn/sandthorn/assignees{/user}","branches_url":"https://api.github.com/repos/Sandthorn/sandthorn/branches{/branch}","tags_url":"https://api.github.com/repos/Sandthorn/sandthorn/tags","blobs_url":"https://api.github.com/repos/Sandthorn/sandthorn/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Sandthorn/sandthorn/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Sandthorn/sandthorn/git/refs{/sha}","trees_url":"https://api.github.com/repos/Sandthorn/sandthorn/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Sandthorn/sandthorn/statuses/{sha}","languages_url":"https://api.github.com/repos/Sandthorn/sandthorn/languages","stargazers_url":"https://api.github.com/repos/Sandthorn/sandthorn/stargazers","contributors_url":"https://api.github.com/repos/Sandthorn/sandthorn/contributors","subscribers_url":"https://api.github.com/repos/Sandthorn/sandthorn/subscribers","subscription_url":"https://api.github.com/repos/Sandthorn/sandthorn/subscription","commits_url":"https://api.github.com/repos/Sandthorn/sandthorn/commits{/sha}","git_commits_url":"https://api.github.com/repos/Sandthorn/sandthorn/git/commits{/sha}","comments_url":"https://api.github.com/repos/Sandthorn/sandthorn/comments{/number}","issue_comment_url":"https://api.github.com/repos/Sandthorn/sandthorn/issues/comments{/number}","contents_url":"https://api.github.com/repos/Sandthorn/sandthorn/contents/{+path}","compare_url":"https://api.github.com/repos/Sandthorn/sandthorn/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Sandthorn/sandthorn/merges","archive_url":"https://api.github.com/repos/Sandthorn/sandthorn/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Sandthorn/sandthorn/downloads","issues_url":"https://api.github.com/repos/Sandthorn/sandthorn/issues{/number}","pulls_url":"https://api.github.com/repos/Sandthorn/sandthorn/pulls{/number}","milestones_url":"https://api.github.com/repos/Sandthorn/sandthorn/milestones{/number}","notifications_url":"https://api.github.com/repos/Sandthorn/sandthorn/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Sandthorn/sandthorn/labels{/name}","releases_url":"https://api.github.com/repos/Sandthorn/sandthorn/releases{/id}","deployments_url":"https://api.github.com/repos/Sandthorn/sandthorn/deployments","created_at":"2013-08-14T07:43:14Z","updated_at":"2018-05-14T04:34:09Z","pushed_at":"2018-05-04T10:53:44Z","git_url":"git://github.com/Sandthorn/sandthorn.git","ssh_url":"git@github.com:Sandthorn/sandthorn.git","clone_url":"https://github.com/Sandthorn/sandthorn.git","svn_url":"https://github.com/Sandthorn/sandthorn","homepage":null,"size":584,"stargazers_count":120,"watchers_count":120,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"archived":false,"open_issues_count":10,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":5,"open_issues":10,"watchers":120,"default_branch":"master"}},"base":{"label":"Sandthorn:master","ref":"master","sha":"9b215b7a0812b3abf1d5c6977e2b85972a2f1467","user":{"login":"Sandthorn","id":5220194,"avatar_url":"https://avatars2.githubusercontent.com/u/5220194?v=4","gravatar_id":"","url":"https://api.github.com/users/Sandthorn","html_url":"https://github.com/Sandthorn","followers_url":"https://api.github.com/users/Sandthorn/followers","following_url":"https://api.github.com/users/Sandthorn/following{/other_user}","gists_url":"https://api.github.com/users/Sandthorn/gists{/gist_id}","starred_url":"https://api.github.com/users/Sandthorn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sandthorn/subscriptions","organizations_url":"https://api.github.com/users/Sandthorn/orgs","repos_url":"https://api.github.com/users/Sandthorn/repos","events_url":"https://api.github.com/users/Sandthorn/events{/privacy}","received_events_url":"https://api.github.com/users/Sandthorn/received_events","type":"Organization","site_admin":false},"repo":{"id":12103058,"name":"sandthorn","full_name":"Sandthorn/sandthorn","owner":{"login":"Sandthorn","id":5220194,"avatar_url":"https://avatars2.githubusercontent.com/u/5220194?v=4","gravatar_id":"","url":"https://api.github.com/users/Sandthorn","html_url":"https://github.com/Sandthorn","followers_url":"https://api.github.com/users/Sandthorn/followers","following_url":"https://api.github.com/users/Sandthorn/following{/other_user}","gists_url":"https://api.github.com/users/Sandthorn/gists{/gist_id}","starred_url":"https://api.github.com/users/Sandthorn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sandthorn/subscriptions","organizations_url":"https://api.github.com/users/Sandthorn/orgs","repos_url":"https://api.github.com/users/Sandthorn/repos","events_url":"https://api.github.com/users/Sandthorn/events{/privacy}","received_events_url":"https://api.github.com/users/Sandthorn/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Sandthorn/sandthorn","description":"Main gem for Sandthorn","fork":false,"url":"https://api.github.com/repos/Sandthorn/sandthorn","forks_url":"https://api.github.com/repos/Sandthorn/sandthorn/forks","keys_url":"https://api.github.com/repos/Sandthorn/sandthorn/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Sandthorn/sandthorn/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Sandthorn/sandthorn/teams","hooks_url":"https://api.github.com/repos/Sandthorn/sandthorn/hooks","issue_events_url":"https://api.github.com/repos/Sandthorn/sandthorn/issues/events{/number}","events_url":"https://api.github.com/repos/Sandthorn/sandthorn/events","assignees_url":"https://api.github.com/repos/Sandthorn/sandthorn/assignees{/user}","branches_url":"https://api.github.com/repos/Sandthorn/sandthorn/branches{/branch}","tags_url":"https://api.github.com/repos/Sandthorn/sandthorn/tags","blobs_url":"https://api.github.com/repos/Sandthorn/sandthorn/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Sandthorn/sandthorn/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Sandthorn/sandthorn/git/refs{/sha}","trees_url":"https://api.github.com/repos/Sandthorn/sandthorn/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Sandthorn/sandthorn/statuses/{sha}","languages_url":"https://api.github.com/repos/Sandthorn/sandthorn/languages","stargazers_url":"https://api.github.com/repos/Sandthorn/sandthorn/stargazers","contributors_url":"https://api.github.com/repos/Sandthorn/sandthorn/contributors","subscribers_url":"https://api.github.com/repos/Sandthorn/sandthorn/subscribers","subscription_url":"https://api.github.com/repos/Sandthorn/sandthorn/subscription","commits_url":"https://api.github.com/repos/Sandthorn/sandthorn/commits{/sha}","git_commits_url":"https://api.github.com/repos/Sandthorn/sandthorn/git/commits{/sha}","comments_url":"https://api.github.com/repos/Sandthorn/sandthorn/comments{/number}","issue_comment_url":"https://api.github.com/repos/Sandthorn/sandthorn/issues/comments{/number}","contents_url":"https://api.github.com/repos/Sandthorn/sandthorn/contents/{+path}","compare_url":"https://api.github.com/repos/Sandthorn/sandthorn/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Sandthorn/sandthorn/merges","archive_url":"https://api.github.com/repos/Sandthorn/sandthorn/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Sandthorn/sandthorn/downloads","issues_url":"https://api.github.com/repos/Sandthorn/sandthorn/issues{/number}","pulls_url":"https://api.github.com/repos/Sandthorn/sandthorn/pulls{/number}","milestones_url":"https://api.github.com/repos/Sandthorn/sandthorn/milestones{/number}","notifications_url":"https://api.github.com/repos/Sandthorn/sandthorn/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Sandthorn/sandthorn/labels{/name}","releases_url":"https://api.github.com/repos/Sandthorn/sandthorn/releases{/id}","deployments_url":"https://api.github.com/repos/Sandthorn/sandthorn/deployments","created_at":"2013-08-14T07:43:14Z","updated_at":"2018-05-14T04:34:09Z","pushed_at":"2018-05-04T10:53:44Z","git_url":"git://github.com/Sandthorn/sandthorn.git","ssh_url":"git@github.com:Sandthorn/sandthorn.git","clone_url":"https://github.com/Sandthorn/sandthorn.git","svn_url":"https://github.com/Sandthorn/sandthorn","homepage":null,"size":584,"stargazers_count":120,"watchers_count":120,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"archived":false,"open_issues_count":10,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":5,"open_issues":10,"watchers":120,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/56"},"html":{"href":"https://github.com/Sandthorn/sandthorn/pull/56"},"issue":{"href":"https://api.github.com/repos/Sandthorn/sandthorn/issues/56"},"comments":{"href":"https://api.github.com/repos/Sandthorn/sandthorn/issues/56/comments"},"review_comments":{"href":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/56/comments"},"review_comment":{"href":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Sandthorn/sandthorn/pulls/56/commits"},"statuses":{"href":"https://api.github.com/repos/Sandthorn/sandthorn/statuses/898f44a41d7b063c21e064e182e618a24d17afcd"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"hallgren"}}