{"action":"created","comment":{"url":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/comments/77124359","id":77124359,"diff_hunk":"@@ -0,0 +1,35 @@\n+require 'rails_helper'\n+\n+RSpec.describe ExpenseType, type: :model do\n+\n+  it 'requires a code' do\n+    expense_type = FactoryGirl.build(:expense_type, :missing_code)\n+    expense_type.valid?\n+    expect(expense_type.errors[:code]).to include(\"can't be blank\")\n+  end\n+\n+  it 'requires a description' do\n+    expense_type = FactoryGirl.build(:expense_type, :missing_description)\n+    expense_type.valid?\n+    expect(expense_type.errors[:description]).to include(\"can't be blank\")\n+  end\n+\n+  it 'has a unique code' do\n+    FactoryGirl.create(:expense_type)\n+    expense_type = FactoryGirl.build(:expense_type)\n+    expense_type.valid?\n+    expect(expense_type.errors[:code]).to include(\"has already been taken\")\n+  end\n+\n+  it 'has a unique description' do\n+    FactoryGirl.create(:expense_type)\n+    expense_type = FactoryGirl.build(:expense_type)\n+    expense_type.valid?\n+    expect(expense_type.errors[:description]).to include(\"has already been taken\")\n+  end\n+\n+  it 'saves to the database with valid attributes' do\n+    expect{ FactoryGirl.create(:expense_type) }.to change(ExpenseType, :count).by(1)\n+  end\n+","path":"spec/models/expense_type_spec.rb","position":34,"original_position":34,"commit_id":"3e3dcc7504dc75173a1c07162e4460ed6e4014ed","original_commit_id":"3e3dcc7504dc75173a1c07162e4460ed6e4014ed","user":{"login":"houndci-bot","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"Extra empty line detected at block body end.","created_at":"2016-09-01T07:13:34Z","updated_at":"2016-09-01T07:13:34Z","html_url":"https://github.com/chrisgartsen/declare_prev/pull/17#discussion_r77124359","pull_request_url":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/17","_links":{"self":{"href":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/comments/77124359"},"html":{"href":"https://github.com/chrisgartsen/declare_prev/pull/17#discussion_r77124359"},"pull_request":{"href":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/17"}}},"pull_request":{"url":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/17","id":83581281,"html_url":"https://github.com/chrisgartsen/declare_prev/pull/17","diff_url":"https://github.com/chrisgartsen/declare_prev/pull/17.diff","patch_url":"https://github.com/chrisgartsen/declare_prev/pull/17.patch","issue_url":"https://api.github.com/repos/chrisgartsen/declare_prev/issues/17","number":17,"state":"open","locked":false,"title":"Expense type","user":{"login":"chrisgartsen","id":56821,"avatar_url":"https://avatars.githubusercontent.com/u/56821?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisgartsen","html_url":"https://github.com/chrisgartsen","followers_url":"https://api.github.com/users/chrisgartsen/followers","following_url":"https://api.github.com/users/chrisgartsen/following{/other_user}","gists_url":"https://api.github.com/users/chrisgartsen/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisgartsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisgartsen/subscriptions","organizations_url":"https://api.github.com/users/chrisgartsen/orgs","repos_url":"https://api.github.com/users/chrisgartsen/repos","events_url":"https://api.github.com/users/chrisgartsen/events{/privacy}","received_events_url":"https://api.github.com/users/chrisgartsen/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-09-01T07:13:27Z","updated_at":"2016-09-01T07:13:34Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4be88b06f18214c6f7daec697ffafff11b3504b8","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/17/commits","review_comments_url":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/17/comments","review_comment_url":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/comments{/number}","comments_url":"https://api.github.com/repos/chrisgartsen/declare_prev/issues/17/comments","statuses_url":"https://api.github.com/repos/chrisgartsen/declare_prev/statuses/3e3dcc7504dc75173a1c07162e4460ed6e4014ed","head":{"label":"chrisgartsen:expense-type","ref":"expense-type","sha":"3e3dcc7504dc75173a1c07162e4460ed6e4014ed","user":{"login":"chrisgartsen","id":56821,"avatar_url":"https://avatars.githubusercontent.com/u/56821?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisgartsen","html_url":"https://github.com/chrisgartsen","followers_url":"https://api.github.com/users/chrisgartsen/followers","following_url":"https://api.github.com/users/chrisgartsen/following{/other_user}","gists_url":"https://api.github.com/users/chrisgartsen/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisgartsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisgartsen/subscriptions","organizations_url":"https://api.github.com/users/chrisgartsen/orgs","repos_url":"https://api.github.com/users/chrisgartsen/repos","events_url":"https://api.github.com/users/chrisgartsen/events{/privacy}","received_events_url":"https://api.github.com/users/chrisgartsen/received_events","type":"User","site_admin":false},"repo":{"id":49529701,"name":"declare_prev","full_name":"chrisgartsen/declare_prev","owner":{"login":"chrisgartsen","id":56821,"avatar_url":"https://avatars.githubusercontent.com/u/56821?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisgartsen","html_url":"https://github.com/chrisgartsen","followers_url":"https://api.github.com/users/chrisgartsen/followers","following_url":"https://api.github.com/users/chrisgartsen/following{/other_user}","gists_url":"https://api.github.com/users/chrisgartsen/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisgartsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisgartsen/subscriptions","organizations_url":"https://api.github.com/users/chrisgartsen/orgs","repos_url":"https://api.github.com/users/chrisgartsen/repos","events_url":"https://api.github.com/users/chrisgartsen/events{/privacy}","received_events_url":"https://api.github.com/users/chrisgartsen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/chrisgartsen/declare_prev","description":"Manage your declarations online","fork":false,"url":"https://api.github.com/repos/chrisgartsen/declare_prev","forks_url":"https://api.github.com/repos/chrisgartsen/declare_prev/forks","keys_url":"https://api.github.com/repos/chrisgartsen/declare_prev/keys{/key_id}","collaborators_url":"https://api.github.com/repos/chrisgartsen/declare_prev/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/chrisgartsen/declare_prev/teams","hooks_url":"https://api.github.com/repos/chrisgartsen/declare_prev/hooks","issue_events_url":"https://api.github.com/repos/chrisgartsen/declare_prev/issues/events{/number}","events_url":"https://api.github.com/repos/chrisgartsen/declare_prev/events","assignees_url":"https://api.github.com/repos/chrisgartsen/declare_prev/assignees{/user}","branches_url":"https://api.github.com/repos/chrisgartsen/declare_prev/branches{/branch}","tags_url":"https://api.github.com/repos/chrisgartsen/declare_prev/tags","blobs_url":"https://api.github.com/repos/chrisgartsen/declare_prev/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/chrisgartsen/declare_prev/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/chrisgartsen/declare_prev/git/refs{/sha}","trees_url":"https://api.github.com/repos/chrisgartsen/declare_prev/git/trees{/sha}","statuses_url":"https://api.github.com/repos/chrisgartsen/declare_prev/statuses/{sha}","languages_url":"https://api.github.com/repos/chrisgartsen/declare_prev/languages","stargazers_url":"https://api.github.com/repos/chrisgartsen/declare_prev/stargazers","contributors_url":"https://api.github.com/repos/chrisgartsen/declare_prev/contributors","subscribers_url":"https://api.github.com/repos/chrisgartsen/declare_prev/subscribers","subscription_url":"https://api.github.com/repos/chrisgartsen/declare_prev/subscription","commits_url":"https://api.github.com/repos/chrisgartsen/declare_prev/commits{/sha}","git_commits_url":"https://api.github.com/repos/chrisgartsen/declare_prev/git/commits{/sha}","comments_url":"https://api.github.com/repos/chrisgartsen/declare_prev/comments{/number}","issue_comment_url":"https://api.github.com/repos/chrisgartsen/declare_prev/issues/comments{/number}","contents_url":"https://api.github.com/repos/chrisgartsen/declare_prev/contents/{+path}","compare_url":"https://api.github.com/repos/chrisgartsen/declare_prev/compare/{base}...{head}","merges_url":"https://api.github.com/repos/chrisgartsen/declare_prev/merges","archive_url":"https://api.github.com/repos/chrisgartsen/declare_prev/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/chrisgartsen/declare_prev/downloads","issues_url":"https://api.github.com/repos/chrisgartsen/declare_prev/issues{/number}","pulls_url":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls{/number}","milestones_url":"https://api.github.com/repos/chrisgartsen/declare_prev/milestones{/number}","notifications_url":"https://api.github.com/repos/chrisgartsen/declare_prev/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/chrisgartsen/declare_prev/labels{/name}","releases_url":"https://api.github.com/repos/chrisgartsen/declare_prev/releases{/id}","deployments_url":"https://api.github.com/repos/chrisgartsen/declare_prev/deployments","created_at":"2016-01-12T21:22:47Z","updated_at":"2016-08-08T20:45:29Z","pushed_at":"2016-09-01T07:13:27Z","git_url":"git://github.com/chrisgartsen/declare_prev.git","ssh_url":"git@github.com:chrisgartsen/declare_prev.git","clone_url":"https://github.com/chrisgartsen/declare_prev.git","svn_url":"https://github.com/chrisgartsen/declare_prev","homepage":null,"size":233,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":3,"forks":0,"open_issues":3,"watchers":0,"default_branch":"master"}},"base":{"label":"chrisgartsen:master","ref":"master","sha":"f5157b06801609eaf87aebab891a6b9c01aae0c0","user":{"login":"chrisgartsen","id":56821,"avatar_url":"https://avatars.githubusercontent.com/u/56821?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisgartsen","html_url":"https://github.com/chrisgartsen","followers_url":"https://api.github.com/users/chrisgartsen/followers","following_url":"https://api.github.com/users/chrisgartsen/following{/other_user}","gists_url":"https://api.github.com/users/chrisgartsen/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisgartsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisgartsen/subscriptions","organizations_url":"https://api.github.com/users/chrisgartsen/orgs","repos_url":"https://api.github.com/users/chrisgartsen/repos","events_url":"https://api.github.com/users/chrisgartsen/events{/privacy}","received_events_url":"https://api.github.com/users/chrisgartsen/received_events","type":"User","site_admin":false},"repo":{"id":49529701,"name":"declare_prev","full_name":"chrisgartsen/declare_prev","owner":{"login":"chrisgartsen","id":56821,"avatar_url":"https://avatars.githubusercontent.com/u/56821?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisgartsen","html_url":"https://github.com/chrisgartsen","followers_url":"https://api.github.com/users/chrisgartsen/followers","following_url":"https://api.github.com/users/chrisgartsen/following{/other_user}","gists_url":"https://api.github.com/users/chrisgartsen/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisgartsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisgartsen/subscriptions","organizations_url":"https://api.github.com/users/chrisgartsen/orgs","repos_url":"https://api.github.com/users/chrisgartsen/repos","events_url":"https://api.github.com/users/chrisgartsen/events{/privacy}","received_events_url":"https://api.github.com/users/chrisgartsen/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/chrisgartsen/declare_prev","description":"Manage your declarations online","fork":false,"url":"https://api.github.com/repos/chrisgartsen/declare_prev","forks_url":"https://api.github.com/repos/chrisgartsen/declare_prev/forks","keys_url":"https://api.github.com/repos/chrisgartsen/declare_prev/keys{/key_id}","collaborators_url":"https://api.github.com/repos/chrisgartsen/declare_prev/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/chrisgartsen/declare_prev/teams","hooks_url":"https://api.github.com/repos/chrisgartsen/declare_prev/hooks","issue_events_url":"https://api.github.com/repos/chrisgartsen/declare_prev/issues/events{/number}","events_url":"https://api.github.com/repos/chrisgartsen/declare_prev/events","assignees_url":"https://api.github.com/repos/chrisgartsen/declare_prev/assignees{/user}","branches_url":"https://api.github.com/repos/chrisgartsen/declare_prev/branches{/branch}","tags_url":"https://api.github.com/repos/chrisgartsen/declare_prev/tags","blobs_url":"https://api.github.com/repos/chrisgartsen/declare_prev/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/chrisgartsen/declare_prev/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/chrisgartsen/declare_prev/git/refs{/sha}","trees_url":"https://api.github.com/repos/chrisgartsen/declare_prev/git/trees{/sha}","statuses_url":"https://api.github.com/repos/chrisgartsen/declare_prev/statuses/{sha}","languages_url":"https://api.github.com/repos/chrisgartsen/declare_prev/languages","stargazers_url":"https://api.github.com/repos/chrisgartsen/declare_prev/stargazers","contributors_url":"https://api.github.com/repos/chrisgartsen/declare_prev/contributors","subscribers_url":"https://api.github.com/repos/chrisgartsen/declare_prev/subscribers","subscription_url":"https://api.github.com/repos/chrisgartsen/declare_prev/subscription","commits_url":"https://api.github.com/repos/chrisgartsen/declare_prev/commits{/sha}","git_commits_url":"https://api.github.com/repos/chrisgartsen/declare_prev/git/commits{/sha}","comments_url":"https://api.github.com/repos/chrisgartsen/declare_prev/comments{/number}","issue_comment_url":"https://api.github.com/repos/chrisgartsen/declare_prev/issues/comments{/number}","contents_url":"https://api.github.com/repos/chrisgartsen/declare_prev/contents/{+path}","compare_url":"https://api.github.com/repos/chrisgartsen/declare_prev/compare/{base}...{head}","merges_url":"https://api.github.com/repos/chrisgartsen/declare_prev/merges","archive_url":"https://api.github.com/repos/chrisgartsen/declare_prev/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/chrisgartsen/declare_prev/downloads","issues_url":"https://api.github.com/repos/chrisgartsen/declare_prev/issues{/number}","pulls_url":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls{/number}","milestones_url":"https://api.github.com/repos/chrisgartsen/declare_prev/milestones{/number}","notifications_url":"https://api.github.com/repos/chrisgartsen/declare_prev/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/chrisgartsen/declare_prev/labels{/name}","releases_url":"https://api.github.com/repos/chrisgartsen/declare_prev/releases{/id}","deployments_url":"https://api.github.com/repos/chrisgartsen/declare_prev/deployments","created_at":"2016-01-12T21:22:47Z","updated_at":"2016-08-08T20:45:29Z","pushed_at":"2016-09-01T07:13:27Z","git_url":"git://github.com/chrisgartsen/declare_prev.git","ssh_url":"git@github.com:chrisgartsen/declare_prev.git","clone_url":"https://github.com/chrisgartsen/declare_prev.git","svn_url":"https://github.com/chrisgartsen/declare_prev","homepage":null,"size":233,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":3,"forks":0,"open_issues":3,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/17"},"html":{"href":"https://github.com/chrisgartsen/declare_prev/pull/17"},"issue":{"href":"https://api.github.com/repos/chrisgartsen/declare_prev/issues/17"},"comments":{"href":"https://api.github.com/repos/chrisgartsen/declare_prev/issues/17/comments"},"review_comments":{"href":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/17/comments"},"review_comment":{"href":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/chrisgartsen/declare_prev/pulls/17/commits"},"statuses":{"href":"https://api.github.com/repos/chrisgartsen/declare_prev/statuses/3e3dcc7504dc75173a1c07162e4460ed6e4014ed"}}}}
{"actor":{"display_login":"houndci-bot"}}