{"action":"created","comment":{"url":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/comments/65799847","id":65799847,"diff_hunk":"@@ -1,6 +1,43 @@\n require 'rails_helper'\n \n describe User do\n+  describe '#increase_grade' do\n+    context '学年がある場合' do\n+      subject { create(:user, :student) }\n+      it '次の学年に更新されている' do\n+        expected = subject.grade.next_grade_code\n+        subject.increase_grade\n+        expect(subject.grade_code).to eq expected\n+      end\n+    end\n+\n+    context '学年がない場合' do\n+      subject { create(:user) }\n+      it '学年が更新されない' do\n+        subject.increase_grade","path":"spec/models/user_spec.rb","position":17,"original_position":17,"commit_id":"ce6ded628e0bdb02faa16d5a8b7ad0c3ee28f37f","original_commit_id":"ce6ded628e0bdb02faa16d5a8b7ad0c3ee28f37f","user":{"login":"JunichiIto","id":1148320,"avatar_url":"https://avatars.githubusercontent.com/u/1148320?v=3","gravatar_id":"","url":"https://api.github.com/users/JunichiIto","html_url":"https://github.com/JunichiIto","followers_url":"https://api.github.com/users/JunichiIto/followers","following_url":"https://api.github.com/users/JunichiIto/following{/other_user}","gists_url":"https://api.github.com/users/JunichiIto/gists{/gist_id}","starred_url":"https://api.github.com/users/JunichiIto/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JunichiIto/subscriptions","organizations_url":"https://api.github.com/users/JunichiIto/orgs","repos_url":"https://api.github.com/users/JunichiIto/repos","events_url":"https://api.github.com/users/JunichiIto/events{/privacy}","received_events_url":"https://api.github.com/users/JunichiIto/received_events","type":"User","site_admin":false},"body":"`expect { subject.increase_grade }.to_not change { subject.grade_code }.from(nil)`","created_at":"2016-06-04T08:58:12Z","updated_at":"2016-06-04T08:58:12Z","html_url":"https://github.com/keisukefunatsu/student-management/pull/88#discussion_r65799847","pull_request_url":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/88","_links":{"self":{"href":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/comments/65799847"},"html":{"href":"https://github.com/keisukefunatsu/student-management/pull/88#discussion_r65799847"},"pull_request":{"href":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/88"}}},"pull_request":{"url":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/88","id":72597279,"html_url":"https://github.com/keisukefunatsu/student-management/pull/88","diff_url":"https://github.com/keisukefunatsu/student-management/pull/88.diff","patch_url":"https://github.com/keisukefunatsu/student-management/pull/88.patch","issue_url":"https://api.github.com/repos/keisukefunatsu/student-management/issues/88","number":88,"state":"open","locked":false,"title":"[WIP] Userの学年を上げるメソッドを追加した","user":{"login":"miytak","id":12821831,"avatar_url":"https://avatars.githubusercontent.com/u/12821831?v=3","gravatar_id":"","url":"https://api.github.com/users/miytak","html_url":"https://github.com/miytak","followers_url":"https://api.github.com/users/miytak/followers","following_url":"https://api.github.com/users/miytak/following{/other_user}","gists_url":"https://api.github.com/users/miytak/gists{/gist_id}","starred_url":"https://api.github.com/users/miytak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miytak/subscriptions","organizations_url":"https://api.github.com/users/miytak/orgs","repos_url":"https://api.github.com/users/miytak/repos","events_url":"https://api.github.com/users/miytak/events{/privacy}","received_events_url":"https://api.github.com/users/miytak/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-06-04T08:46:38Z","updated_at":"2016-06-04T08:58:13Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e675bdf183e2ec05285d279ec63d47818dbedf17","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/88/commits","review_comments_url":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/88/comments","review_comment_url":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/comments{/number}","comments_url":"https://api.github.com/repos/keisukefunatsu/student-management/issues/88/comments","statuses_url":"https://api.github.com/repos/keisukefunatsu/student-management/statuses/ce6ded628e0bdb02faa16d5a8b7ad0c3ee28f37f","head":{"label":"miytak:issue-74-student-grade","ref":"issue-74-student-grade","sha":"ce6ded628e0bdb02faa16d5a8b7ad0c3ee28f37f","user":{"login":"miytak","id":12821831,"avatar_url":"https://avatars.githubusercontent.com/u/12821831?v=3","gravatar_id":"","url":"https://api.github.com/users/miytak","html_url":"https://github.com/miytak","followers_url":"https://api.github.com/users/miytak/followers","following_url":"https://api.github.com/users/miytak/following{/other_user}","gists_url":"https://api.github.com/users/miytak/gists{/gist_id}","starred_url":"https://api.github.com/users/miytak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miytak/subscriptions","organizations_url":"https://api.github.com/users/miytak/orgs","repos_url":"https://api.github.com/users/miytak/repos","events_url":"https://api.github.com/users/miytak/events{/privacy}","received_events_url":"https://api.github.com/users/miytak/received_events","type":"User","site_admin":false},"repo":{"id":59928497,"name":"student-management","full_name":"miytak/student-management","owner":{"login":"miytak","id":12821831,"avatar_url":"https://avatars.githubusercontent.com/u/12821831?v=3","gravatar_id":"","url":"https://api.github.com/users/miytak","html_url":"https://github.com/miytak","followers_url":"https://api.github.com/users/miytak/followers","following_url":"https://api.github.com/users/miytak/following{/other_user}","gists_url":"https://api.github.com/users/miytak/gists{/gist_id}","starred_url":"https://api.github.com/users/miytak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miytak/subscriptions","organizations_url":"https://api.github.com/users/miytak/orgs","repos_url":"https://api.github.com/users/miytak/repos","events_url":"https://api.github.com/users/miytak/events{/privacy}","received_events_url":"https://api.github.com/users/miytak/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/miytak/student-management","description":"","fork":true,"url":"https://api.github.com/repos/miytak/student-management","forks_url":"https://api.github.com/repos/miytak/student-management/forks","keys_url":"https://api.github.com/repos/miytak/student-management/keys{/key_id}","collaborators_url":"https://api.github.com/repos/miytak/student-management/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/miytak/student-management/teams","hooks_url":"https://api.github.com/repos/miytak/student-management/hooks","issue_events_url":"https://api.github.com/repos/miytak/student-management/issues/events{/number}","events_url":"https://api.github.com/repos/miytak/student-management/events","assignees_url":"https://api.github.com/repos/miytak/student-management/assignees{/user}","branches_url":"https://api.github.com/repos/miytak/student-management/branches{/branch}","tags_url":"https://api.github.com/repos/miytak/student-management/tags","blobs_url":"https://api.github.com/repos/miytak/student-management/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/miytak/student-management/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/miytak/student-management/git/refs{/sha}","trees_url":"https://api.github.com/repos/miytak/student-management/git/trees{/sha}","statuses_url":"https://api.github.com/repos/miytak/student-management/statuses/{sha}","languages_url":"https://api.github.com/repos/miytak/student-management/languages","stargazers_url":"https://api.github.com/repos/miytak/student-management/stargazers","contributors_url":"https://api.github.com/repos/miytak/student-management/contributors","subscribers_url":"https://api.github.com/repos/miytak/student-management/subscribers","subscription_url":"https://api.github.com/repos/miytak/student-management/subscription","commits_url":"https://api.github.com/repos/miytak/student-management/commits{/sha}","git_commits_url":"https://api.github.com/repos/miytak/student-management/git/commits{/sha}","comments_url":"https://api.github.com/repos/miytak/student-management/comments{/number}","issue_comment_url":"https://api.github.com/repos/miytak/student-management/issues/comments{/number}","contents_url":"https://api.github.com/repos/miytak/student-management/contents/{+path}","compare_url":"https://api.github.com/repos/miytak/student-management/compare/{base}...{head}","merges_url":"https://api.github.com/repos/miytak/student-management/merges","archive_url":"https://api.github.com/repos/miytak/student-management/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/miytak/student-management/downloads","issues_url":"https://api.github.com/repos/miytak/student-management/issues{/number}","pulls_url":"https://api.github.com/repos/miytak/student-management/pulls{/number}","milestones_url":"https://api.github.com/repos/miytak/student-management/milestones{/number}","notifications_url":"https://api.github.com/repos/miytak/student-management/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/miytak/student-management/labels{/name}","releases_url":"https://api.github.com/repos/miytak/student-management/releases{/id}","deployments_url":"https://api.github.com/repos/miytak/student-management/deployments","created_at":"2016-05-29T05:49:06Z","updated_at":"2016-05-29T05:49:07Z","pushed_at":"2016-06-04T08:45:02Z","git_url":"git://github.com/miytak/student-management.git","ssh_url":"git@github.com:miytak/student-management.git","clone_url":"https://github.com/miytak/student-management.git","svn_url":"https://github.com/miytak/student-management","homepage":null,"size":1490,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_downloads":true,"has_wiki":true,"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":"keisukefunatsu:master","ref":"master","sha":"5c2b057be848cf3d03a4ef78cb60c53510724a1f","user":{"login":"keisukefunatsu","id":8057058,"avatar_url":"https://avatars.githubusercontent.com/u/8057058?v=3","gravatar_id":"","url":"https://api.github.com/users/keisukefunatsu","html_url":"https://github.com/keisukefunatsu","followers_url":"https://api.github.com/users/keisukefunatsu/followers","following_url":"https://api.github.com/users/keisukefunatsu/following{/other_user}","gists_url":"https://api.github.com/users/keisukefunatsu/gists{/gist_id}","starred_url":"https://api.github.com/users/keisukefunatsu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/keisukefunatsu/subscriptions","organizations_url":"https://api.github.com/users/keisukefunatsu/orgs","repos_url":"https://api.github.com/users/keisukefunatsu/repos","events_url":"https://api.github.com/users/keisukefunatsu/events{/privacy}","received_events_url":"https://api.github.com/users/keisukefunatsu/received_events","type":"User","site_admin":false},"repo":{"id":56741465,"name":"student-management","full_name":"keisukefunatsu/student-management","owner":{"login":"keisukefunatsu","id":8057058,"avatar_url":"https://avatars.githubusercontent.com/u/8057058?v=3","gravatar_id":"","url":"https://api.github.com/users/keisukefunatsu","html_url":"https://github.com/keisukefunatsu","followers_url":"https://api.github.com/users/keisukefunatsu/followers","following_url":"https://api.github.com/users/keisukefunatsu/following{/other_user}","gists_url":"https://api.github.com/users/keisukefunatsu/gists{/gist_id}","starred_url":"https://api.github.com/users/keisukefunatsu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/keisukefunatsu/subscriptions","organizations_url":"https://api.github.com/users/keisukefunatsu/orgs","repos_url":"https://api.github.com/users/keisukefunatsu/repos","events_url":"https://api.github.com/users/keisukefunatsu/events{/privacy}","received_events_url":"https://api.github.com/users/keisukefunatsu/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/keisukefunatsu/student-management","description":"","fork":false,"url":"https://api.github.com/repos/keisukefunatsu/student-management","forks_url":"https://api.github.com/repos/keisukefunatsu/student-management/forks","keys_url":"https://api.github.com/repos/keisukefunatsu/student-management/keys{/key_id}","collaborators_url":"https://api.github.com/repos/keisukefunatsu/student-management/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/keisukefunatsu/student-management/teams","hooks_url":"https://api.github.com/repos/keisukefunatsu/student-management/hooks","issue_events_url":"https://api.github.com/repos/keisukefunatsu/student-management/issues/events{/number}","events_url":"https://api.github.com/repos/keisukefunatsu/student-management/events","assignees_url":"https://api.github.com/repos/keisukefunatsu/student-management/assignees{/user}","branches_url":"https://api.github.com/repos/keisukefunatsu/student-management/branches{/branch}","tags_url":"https://api.github.com/repos/keisukefunatsu/student-management/tags","blobs_url":"https://api.github.com/repos/keisukefunatsu/student-management/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/keisukefunatsu/student-management/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/keisukefunatsu/student-management/git/refs{/sha}","trees_url":"https://api.github.com/repos/keisukefunatsu/student-management/git/trees{/sha}","statuses_url":"https://api.github.com/repos/keisukefunatsu/student-management/statuses/{sha}","languages_url":"https://api.github.com/repos/keisukefunatsu/student-management/languages","stargazers_url":"https://api.github.com/repos/keisukefunatsu/student-management/stargazers","contributors_url":"https://api.github.com/repos/keisukefunatsu/student-management/contributors","subscribers_url":"https://api.github.com/repos/keisukefunatsu/student-management/subscribers","subscription_url":"https://api.github.com/repos/keisukefunatsu/student-management/subscription","commits_url":"https://api.github.com/repos/keisukefunatsu/student-management/commits{/sha}","git_commits_url":"https://api.github.com/repos/keisukefunatsu/student-management/git/commits{/sha}","comments_url":"https://api.github.com/repos/keisukefunatsu/student-management/comments{/number}","issue_comment_url":"https://api.github.com/repos/keisukefunatsu/student-management/issues/comments{/number}","contents_url":"https://api.github.com/repos/keisukefunatsu/student-management/contents/{+path}","compare_url":"https://api.github.com/repos/keisukefunatsu/student-management/compare/{base}...{head}","merges_url":"https://api.github.com/repos/keisukefunatsu/student-management/merges","archive_url":"https://api.github.com/repos/keisukefunatsu/student-management/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/keisukefunatsu/student-management/downloads","issues_url":"https://api.github.com/repos/keisukefunatsu/student-management/issues{/number}","pulls_url":"https://api.github.com/repos/keisukefunatsu/student-management/pulls{/number}","milestones_url":"https://api.github.com/repos/keisukefunatsu/student-management/milestones{/number}","notifications_url":"https://api.github.com/repos/keisukefunatsu/student-management/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/keisukefunatsu/student-management/labels{/name}","releases_url":"https://api.github.com/repos/keisukefunatsu/student-management/releases{/id}","deployments_url":"https://api.github.com/repos/keisukefunatsu/student-management/deployments","created_at":"2016-04-21T04:04:28Z","updated_at":"2016-04-21T04:07:00Z","pushed_at":"2016-06-04T08:55:41Z","git_url":"git://github.com/keisukefunatsu/student-management.git","ssh_url":"git@github.com:keisukefunatsu/student-management.git","clone_url":"https://github.com/keisukefunatsu/student-management.git","svn_url":"https://github.com/keisukefunatsu/student-management","homepage":null,"size":1501,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":13,"mirror_url":null,"open_issues_count":67,"forks":13,"open_issues":67,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/88"},"html":{"href":"https://github.com/keisukefunatsu/student-management/pull/88"},"issue":{"href":"https://api.github.com/repos/keisukefunatsu/student-management/issues/88"},"comments":{"href":"https://api.github.com/repos/keisukefunatsu/student-management/issues/88/comments"},"review_comments":{"href":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/88/comments"},"review_comment":{"href":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/keisukefunatsu/student-management/pulls/88/commits"},"statuses":{"href":"https://api.github.com/repos/keisukefunatsu/student-management/statuses/ce6ded628e0bdb02faa16d5a8b7ad0c3ee28f37f"}}}}
{"actor":{"display_login":"JunichiIto"}}