{"action":"created","comment":{"url":"https://api.github.com/repos/TeamConchord/earmarked/pulls/comments/40742053","id":40742053,"diff_hunk":"@@ -1,5 +1,54 @@\n require 'rails_helper'\n \n RSpec.describe Donation, type: :model do\n-  pending \"add some examples to (or delete) #{__FILE__}\"\n+  context \"is valid with proper attributes\" do\n+    let(:user) {\n+      User.create(first_name: \"Donald\", last_name: \"Trump\", email: \"trump@luxury.com\", username: \"therealtrump\", password: \"password\", password_confirmation: \"password\")\n+    }\n+    let(:candidate_issue) {\n+      CandidateIssue.create\n+    }\n+\n+    let(:valid_attributes) do\n+      {\n+                    amount: 100,\n+        candidate_issue_id: candidate_issue.id,\n+                   user_id: user.id\n+      }\n+    end\n+\n+    let(:donation) { Donation.create(valid_attributes) }\n+\n+    it \"is valid\" do\n+      expect(donation).to be_valid\n+    end\n+\n+    it \"has an amount\" do\n+      expect(donation.amount).to eq(100)\n+    end\n+\n+    it \"has a candidate_issue_id\" do\n+      expect(donation.candidate_issue_id).to eq(candidate_issue.id)\n+    end\n+\n+    it \"has a user_id\" do\n+      expect(donation.user_id).to eq(user.id)\n+    end\n+  end\n+\n+  context \"with invalid attributes\" do\n+    let(:invalid_attributes) do\n+       {\n+                    amount: nil,\n+        candidate_issue_id: nil,\n+                   user_id: nil","path":"spec/models/donation_spec.rb","position":45,"original_position":45,"commit_id":"8c86df6f178c4005b8cbf3f6a545880b62230ae2","original_commit_id":"8c86df6f178c4005b8cbf3f6a545880b62230ae2","user":{"login":"houndci","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci","html_url":"https://github.com/houndci","followers_url":"https://api.github.com/users/houndci/followers","following_url":"https://api.github.com/users/houndci/following{/other_user}","gists_url":"https://api.github.com/users/houndci/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci/subscriptions","organizations_url":"https://api.github.com/users/houndci/orgs","repos_url":"https://api.github.com/users/houndci/repos","events_url":"https://api.github.com/users/houndci/events{/privacy}","received_events_url":"https://api.github.com/users/houndci/received_events","type":"User","site_admin":false},"body":"Align the elements of a hash literal if they span more than one line.","created_at":"2015-09-29T23:03:22Z","updated_at":"2015-09-29T23:03:22Z","html_url":"https://github.com/TeamConchord/earmarked/pull/149#discussion_r40742053","pull_request_url":"https://api.github.com/repos/TeamConchord/earmarked/pulls/149","_links":{"self":{"href":"https://api.github.com/repos/TeamConchord/earmarked/pulls/comments/40742053"},"html":{"href":"https://github.com/TeamConchord/earmarked/pull/149#discussion_r40742053"},"pull_request":{"href":"https://api.github.com/repos/TeamConchord/earmarked/pulls/149"}}},"pull_request":{"url":"https://api.github.com/repos/TeamConchord/earmarked/pulls/149","id":46343492,"html_url":"https://github.com/TeamConchord/earmarked/pull/149","diff_url":"https://github.com/TeamConchord/earmarked/pull/149.diff","patch_url":"https://github.com/TeamConchord/earmarked/pull/149.patch","issue_url":"https://api.github.com/repos/TeamConchord/earmarked/issues/149","number":149,"state":"open","locked":false,"title":"144 add cart total to navbar when cart has donations closes #144","user":{"login":"travishaby","id":10556957,"avatar_url":"https://avatars.githubusercontent.com/u/10556957?v=3","gravatar_id":"","url":"https://api.github.com/users/travishaby","html_url":"https://github.com/travishaby","followers_url":"https://api.github.com/users/travishaby/followers","following_url":"https://api.github.com/users/travishaby/following{/other_user}","gists_url":"https://api.github.com/users/travishaby/gists{/gist_id}","starred_url":"https://api.github.com/users/travishaby/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/travishaby/subscriptions","organizations_url":"https://api.github.com/users/travishaby/orgs","repos_url":"https://api.github.com/users/travishaby/repos","events_url":"https://api.github.com/users/travishaby/events{/privacy}","received_events_url":"https://api.github.com/users/travishaby/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-09-29T23:03:17Z","updated_at":"2015-09-29T23:03:22Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0d9335366bb2e16e2a00b31d5ad240028500ce6e","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/TeamConchord/earmarked/pulls/149/commits","review_comments_url":"https://api.github.com/repos/TeamConchord/earmarked/pulls/149/comments","review_comment_url":"https://api.github.com/repos/TeamConchord/earmarked/pulls/comments{/number}","comments_url":"https://api.github.com/repos/TeamConchord/earmarked/issues/149/comments","statuses_url":"https://api.github.com/repos/TeamConchord/earmarked/statuses/8c86df6f178c4005b8cbf3f6a545880b62230ae2","head":{"label":"TeamConchord:144-add-cart-total-to-navbar-when-cart-has-donations","ref":"144-add-cart-total-to-navbar-when-cart-has-donations","sha":"8c86df6f178c4005b8cbf3f6a545880b62230ae2","user":{"login":"TeamConchord","id":14790541,"avatar_url":"https://avatars.githubusercontent.com/u/14790541?v=3","gravatar_id":"","url":"https://api.github.com/users/TeamConchord","html_url":"https://github.com/TeamConchord","followers_url":"https://api.github.com/users/TeamConchord/followers","following_url":"https://api.github.com/users/TeamConchord/following{/other_user}","gists_url":"https://api.github.com/users/TeamConchord/gists{/gist_id}","starred_url":"https://api.github.com/users/TeamConchord/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TeamConchord/subscriptions","organizations_url":"https://api.github.com/users/TeamConchord/orgs","repos_url":"https://api.github.com/users/TeamConchord/repos","events_url":"https://api.github.com/users/TeamConchord/events{/privacy}","received_events_url":"https://api.github.com/users/TeamConchord/received_events","type":"Organization","site_admin":false},"repo":{"id":42945674,"name":"earmarked","full_name":"TeamConchord/earmarked","owner":{"login":"TeamConchord","id":14790541,"avatar_url":"https://avatars.githubusercontent.com/u/14790541?v=3","gravatar_id":"","url":"https://api.github.com/users/TeamConchord","html_url":"https://github.com/TeamConchord","followers_url":"https://api.github.com/users/TeamConchord/followers","following_url":"https://api.github.com/users/TeamConchord/following{/other_user}","gists_url":"https://api.github.com/users/TeamConchord/gists{/gist_id}","starred_url":"https://api.github.com/users/TeamConchord/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TeamConchord/subscriptions","organizations_url":"https://api.github.com/users/TeamConchord/orgs","repos_url":"https://api.github.com/users/TeamConchord/repos","events_url":"https://api.github.com/users/TeamConchord/events{/privacy}","received_events_url":"https://api.github.com/users/TeamConchord/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/TeamConchord/earmarked","description":"key","fork":false,"url":"https://api.github.com/repos/TeamConchord/earmarked","forks_url":"https://api.github.com/repos/TeamConchord/earmarked/forks","keys_url":"https://api.github.com/repos/TeamConchord/earmarked/keys{/key_id}","collaborators_url":"https://api.github.com/repos/TeamConchord/earmarked/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/TeamConchord/earmarked/teams","hooks_url":"https://api.github.com/repos/TeamConchord/earmarked/hooks","issue_events_url":"https://api.github.com/repos/TeamConchord/earmarked/issues/events{/number}","events_url":"https://api.github.com/repos/TeamConchord/earmarked/events","assignees_url":"https://api.github.com/repos/TeamConchord/earmarked/assignees{/user}","branches_url":"https://api.github.com/repos/TeamConchord/earmarked/branches{/branch}","tags_url":"https://api.github.com/repos/TeamConchord/earmarked/tags","blobs_url":"https://api.github.com/repos/TeamConchord/earmarked/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/TeamConchord/earmarked/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/TeamConchord/earmarked/git/refs{/sha}","trees_url":"https://api.github.com/repos/TeamConchord/earmarked/git/trees{/sha}","statuses_url":"https://api.github.com/repos/TeamConchord/earmarked/statuses/{sha}","languages_url":"https://api.github.com/repos/TeamConchord/earmarked/languages","stargazers_url":"https://api.github.com/repos/TeamConchord/earmarked/stargazers","contributors_url":"https://api.github.com/repos/TeamConchord/earmarked/contributors","subscribers_url":"https://api.github.com/repos/TeamConchord/earmarked/subscribers","subscription_url":"https://api.github.com/repos/TeamConchord/earmarked/subscription","commits_url":"https://api.github.com/repos/TeamConchord/earmarked/commits{/sha}","git_commits_url":"https://api.github.com/repos/TeamConchord/earmarked/git/commits{/sha}","comments_url":"https://api.github.com/repos/TeamConchord/earmarked/comments{/number}","issue_comment_url":"https://api.github.com/repos/TeamConchord/earmarked/issues/comments{/number}","contents_url":"https://api.github.com/repos/TeamConchord/earmarked/contents/{+path}","compare_url":"https://api.github.com/repos/TeamConchord/earmarked/compare/{base}...{head}","merges_url":"https://api.github.com/repos/TeamConchord/earmarked/merges","archive_url":"https://api.github.com/repos/TeamConchord/earmarked/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/TeamConchord/earmarked/downloads","issues_url":"https://api.github.com/repos/TeamConchord/earmarked/issues{/number}","pulls_url":"https://api.github.com/repos/TeamConchord/earmarked/pulls{/number}","milestones_url":"https://api.github.com/repos/TeamConchord/earmarked/milestones{/number}","notifications_url":"https://api.github.com/repos/TeamConchord/earmarked/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/TeamConchord/earmarked/labels{/name}","releases_url":"https://api.github.com/repos/TeamConchord/earmarked/releases{/id}","created_at":"2015-09-22T16:18:06Z","updated_at":"2015-09-24T16:47:33Z","pushed_at":"2015-09-29T23:03:17Z","git_url":"git://github.com/TeamConchord/earmarked.git","ssh_url":"git@github.com:TeamConchord/earmarked.git","clone_url":"https://github.com/TeamConchord/earmarked.git","svn_url":"https://github.com/TeamConchord/earmarked","homepage":"","size":4312,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":12,"forks":1,"open_issues":12,"watchers":0,"default_branch":"master"}},"base":{"label":"TeamConchord:master","ref":"master","sha":"c34ac880842385e71168e6c541f2f44a788d32f5","user":{"login":"TeamConchord","id":14790541,"avatar_url":"https://avatars.githubusercontent.com/u/14790541?v=3","gravatar_id":"","url":"https://api.github.com/users/TeamConchord","html_url":"https://github.com/TeamConchord","followers_url":"https://api.github.com/users/TeamConchord/followers","following_url":"https://api.github.com/users/TeamConchord/following{/other_user}","gists_url":"https://api.github.com/users/TeamConchord/gists{/gist_id}","starred_url":"https://api.github.com/users/TeamConchord/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TeamConchord/subscriptions","organizations_url":"https://api.github.com/users/TeamConchord/orgs","repos_url":"https://api.github.com/users/TeamConchord/repos","events_url":"https://api.github.com/users/TeamConchord/events{/privacy}","received_events_url":"https://api.github.com/users/TeamConchord/received_events","type":"Organization","site_admin":false},"repo":{"id":42945674,"name":"earmarked","full_name":"TeamConchord/earmarked","owner":{"login":"TeamConchord","id":14790541,"avatar_url":"https://avatars.githubusercontent.com/u/14790541?v=3","gravatar_id":"","url":"https://api.github.com/users/TeamConchord","html_url":"https://github.com/TeamConchord","followers_url":"https://api.github.com/users/TeamConchord/followers","following_url":"https://api.github.com/users/TeamConchord/following{/other_user}","gists_url":"https://api.github.com/users/TeamConchord/gists{/gist_id}","starred_url":"https://api.github.com/users/TeamConchord/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TeamConchord/subscriptions","organizations_url":"https://api.github.com/users/TeamConchord/orgs","repos_url":"https://api.github.com/users/TeamConchord/repos","events_url":"https://api.github.com/users/TeamConchord/events{/privacy}","received_events_url":"https://api.github.com/users/TeamConchord/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/TeamConchord/earmarked","description":"key","fork":false,"url":"https://api.github.com/repos/TeamConchord/earmarked","forks_url":"https://api.github.com/repos/TeamConchord/earmarked/forks","keys_url":"https://api.github.com/repos/TeamConchord/earmarked/keys{/key_id}","collaborators_url":"https://api.github.com/repos/TeamConchord/earmarked/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/TeamConchord/earmarked/teams","hooks_url":"https://api.github.com/repos/TeamConchord/earmarked/hooks","issue_events_url":"https://api.github.com/repos/TeamConchord/earmarked/issues/events{/number}","events_url":"https://api.github.com/repos/TeamConchord/earmarked/events","assignees_url":"https://api.github.com/repos/TeamConchord/earmarked/assignees{/user}","branches_url":"https://api.github.com/repos/TeamConchord/earmarked/branches{/branch}","tags_url":"https://api.github.com/repos/TeamConchord/earmarked/tags","blobs_url":"https://api.github.com/repos/TeamConchord/earmarked/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/TeamConchord/earmarked/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/TeamConchord/earmarked/git/refs{/sha}","trees_url":"https://api.github.com/repos/TeamConchord/earmarked/git/trees{/sha}","statuses_url":"https://api.github.com/repos/TeamConchord/earmarked/statuses/{sha}","languages_url":"https://api.github.com/repos/TeamConchord/earmarked/languages","stargazers_url":"https://api.github.com/repos/TeamConchord/earmarked/stargazers","contributors_url":"https://api.github.com/repos/TeamConchord/earmarked/contributors","subscribers_url":"https://api.github.com/repos/TeamConchord/earmarked/subscribers","subscription_url":"https://api.github.com/repos/TeamConchord/earmarked/subscription","commits_url":"https://api.github.com/repos/TeamConchord/earmarked/commits{/sha}","git_commits_url":"https://api.github.com/repos/TeamConchord/earmarked/git/commits{/sha}","comments_url":"https://api.github.com/repos/TeamConchord/earmarked/comments{/number}","issue_comment_url":"https://api.github.com/repos/TeamConchord/earmarked/issues/comments{/number}","contents_url":"https://api.github.com/repos/TeamConchord/earmarked/contents/{+path}","compare_url":"https://api.github.com/repos/TeamConchord/earmarked/compare/{base}...{head}","merges_url":"https://api.github.com/repos/TeamConchord/earmarked/merges","archive_url":"https://api.github.com/repos/TeamConchord/earmarked/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/TeamConchord/earmarked/downloads","issues_url":"https://api.github.com/repos/TeamConchord/earmarked/issues{/number}","pulls_url":"https://api.github.com/repos/TeamConchord/earmarked/pulls{/number}","milestones_url":"https://api.github.com/repos/TeamConchord/earmarked/milestones{/number}","notifications_url":"https://api.github.com/repos/TeamConchord/earmarked/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/TeamConchord/earmarked/labels{/name}","releases_url":"https://api.github.com/repos/TeamConchord/earmarked/releases{/id}","created_at":"2015-09-22T16:18:06Z","updated_at":"2015-09-24T16:47:33Z","pushed_at":"2015-09-29T23:03:17Z","git_url":"git://github.com/TeamConchord/earmarked.git","ssh_url":"git@github.com:TeamConchord/earmarked.git","clone_url":"https://github.com/TeamConchord/earmarked.git","svn_url":"https://github.com/TeamConchord/earmarked","homepage":"","size":4312,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":12,"forks":1,"open_issues":12,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/TeamConchord/earmarked/pulls/149"},"html":{"href":"https://github.com/TeamConchord/earmarked/pull/149"},"issue":{"href":"https://api.github.com/repos/TeamConchord/earmarked/issues/149"},"comments":{"href":"https://api.github.com/repos/TeamConchord/earmarked/issues/149/comments"},"review_comments":{"href":"https://api.github.com/repos/TeamConchord/earmarked/pulls/149/comments"},"review_comment":{"href":"https://api.github.com/repos/TeamConchord/earmarked/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/TeamConchord/earmarked/pulls/149/commits"},"statuses":{"href":"https://api.github.com/repos/TeamConchord/earmarked/statuses/8c86df6f178c4005b8cbf3f6a545880b62230ae2"}}}}