{"action":"created","comment":{"url":"https://api.github.com/repos/valadzko/qna/pulls/comments/44857190","id":44857190,"diff_hunk":"@@ -0,0 +1,9 @@\n+require 'rails_helper'\n+\n+RSpec.describe Question, type: :model do\n+  it { should validate_presence_of :title }\n+  it { should validate_presence_of :body }\n+  it { should validate_length_of(:title).is_at_least(5) }\n+  it { should validate_length_of(:body).is_at_least(10) }\n+  it { should have_many(:answer) }","path":"spec/models/question_spec.rb","position":8,"original_position":8,"commit_id":"2630c619ce70e66fb8ec50d0a4edbc6b13085f40","original_commit_id":"2630c619ce70e66fb8ec50d0a4edbc6b13085f40","user":{"login":"vkurennov","id":968537,"avatar_url":"https://avatars.githubusercontent.com/u/968537?v=3","gravatar_id":"","url":"https://api.github.com/users/vkurennov","html_url":"https://github.com/vkurennov","followers_url":"https://api.github.com/users/vkurennov/followers","following_url":"https://api.github.com/users/vkurennov/following{/other_user}","gists_url":"https://api.github.com/users/vkurennov/gists{/gist_id}","starred_url":"https://api.github.com/users/vkurennov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vkurennov/subscriptions","organizations_url":"https://api.github.com/users/vkurennov/orgs","repos_url":"https://api.github.com/users/vkurennov/repos","events_url":"https://api.github.com/users/vkurennov/events{/privacy}","received_events_url":"https://api.github.com/users/vkurennov/received_events","type":"User","site_admin":false},"body":"Тут надо учесть, что у тебя ассоциация с опцией destroy и чуток изменить тест: `have_many(:answer).dependent(:destroy)`","created_at":"2015-11-14T10:28:39Z","updated_at":"2015-11-14T10:28:39Z","html_url":"https://github.com/valadzko/qna/pull/1#discussion_r44857190","pull_request_url":"https://api.github.com/repos/valadzko/qna/pulls/1","_links":{"self":{"href":"https://api.github.com/repos/valadzko/qna/pulls/comments/44857190"},"html":{"href":"https://github.com/valadzko/qna/pull/1#discussion_r44857190"},"pull_request":{"href":"https://api.github.com/repos/valadzko/qna/pulls/1"}}},"pull_request":{"url":"https://api.github.com/repos/valadzko/qna/pulls/1","id":50720683,"html_url":"https://github.com/valadzko/qna/pull/1","diff_url":"https://github.com/valadzko/qna/pull/1.diff","patch_url":"https://github.com/valadzko/qna/pull/1.patch","issue_url":"https://api.github.com/repos/valadzko/qna/issues/1","number":1,"state":"open","locked":false,"title":"Feature/1/qa models","user":{"login":"valadzko","id":12141346,"avatar_url":"https://avatars.githubusercontent.com/u/12141346?v=3","gravatar_id":"","url":"https://api.github.com/users/valadzko","html_url":"https://github.com/valadzko","followers_url":"https://api.github.com/users/valadzko/followers","following_url":"https://api.github.com/users/valadzko/following{/other_user}","gists_url":"https://api.github.com/users/valadzko/gists{/gist_id}","starred_url":"https://api.github.com/users/valadzko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/valadzko/subscriptions","organizations_url":"https://api.github.com/users/valadzko/orgs","repos_url":"https://api.github.com/users/valadzko/repos","events_url":"https://api.github.com/users/valadzko/events{/privacy}","received_events_url":"https://api.github.com/users/valadzko/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-11-14T10:01:29Z","updated_at":"2015-11-14T10:28:39Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1f5e00bc227a8064d739055350e0fbc519546bff","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/valadzko/qna/pulls/1/commits","review_comments_url":"https://api.github.com/repos/valadzko/qna/pulls/1/comments","review_comment_url":"https://api.github.com/repos/valadzko/qna/pulls/comments{/number}","comments_url":"https://api.github.com/repos/valadzko/qna/issues/1/comments","statuses_url":"https://api.github.com/repos/valadzko/qna/statuses/2630c619ce70e66fb8ec50d0a4edbc6b13085f40","head":{"label":"valadzko:feature/1/qa-models","ref":"feature/1/qa-models","sha":"2630c619ce70e66fb8ec50d0a4edbc6b13085f40","user":{"login":"valadzko","id":12141346,"avatar_url":"https://avatars.githubusercontent.com/u/12141346?v=3","gravatar_id":"","url":"https://api.github.com/users/valadzko","html_url":"https://github.com/valadzko","followers_url":"https://api.github.com/users/valadzko/followers","following_url":"https://api.github.com/users/valadzko/following{/other_user}","gists_url":"https://api.github.com/users/valadzko/gists{/gist_id}","starred_url":"https://api.github.com/users/valadzko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/valadzko/subscriptions","organizations_url":"https://api.github.com/users/valadzko/orgs","repos_url":"https://api.github.com/users/valadzko/repos","events_url":"https://api.github.com/users/valadzko/events{/privacy}","received_events_url":"https://api.github.com/users/valadzko/received_events","type":"User","site_admin":false},"repo":{"id":46003913,"name":"qna","full_name":"valadzko/qna","owner":{"login":"valadzko","id":12141346,"avatar_url":"https://avatars.githubusercontent.com/u/12141346?v=3","gravatar_id":"","url":"https://api.github.com/users/valadzko","html_url":"https://github.com/valadzko","followers_url":"https://api.github.com/users/valadzko/followers","following_url":"https://api.github.com/users/valadzko/following{/other_user}","gists_url":"https://api.github.com/users/valadzko/gists{/gist_id}","starred_url":"https://api.github.com/users/valadzko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/valadzko/subscriptions","organizations_url":"https://api.github.com/users/valadzko/orgs","repos_url":"https://api.github.com/users/valadzko/repos","events_url":"https://api.github.com/users/valadzko/events{/privacy}","received_events_url":"https://api.github.com/users/valadzko/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/valadzko/qna","description":"","fork":false,"url":"https://api.github.com/repos/valadzko/qna","forks_url":"https://api.github.com/repos/valadzko/qna/forks","keys_url":"https://api.github.com/repos/valadzko/qna/keys{/key_id}","collaborators_url":"https://api.github.com/repos/valadzko/qna/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/valadzko/qna/teams","hooks_url":"https://api.github.com/repos/valadzko/qna/hooks","issue_events_url":"https://api.github.com/repos/valadzko/qna/issues/events{/number}","events_url":"https://api.github.com/repos/valadzko/qna/events","assignees_url":"https://api.github.com/repos/valadzko/qna/assignees{/user}","branches_url":"https://api.github.com/repos/valadzko/qna/branches{/branch}","tags_url":"https://api.github.com/repos/valadzko/qna/tags","blobs_url":"https://api.github.com/repos/valadzko/qna/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/valadzko/qna/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/valadzko/qna/git/refs{/sha}","trees_url":"https://api.github.com/repos/valadzko/qna/git/trees{/sha}","statuses_url":"https://api.github.com/repos/valadzko/qna/statuses/{sha}","languages_url":"https://api.github.com/repos/valadzko/qna/languages","stargazers_url":"https://api.github.com/repos/valadzko/qna/stargazers","contributors_url":"https://api.github.com/repos/valadzko/qna/contributors","subscribers_url":"https://api.github.com/repos/valadzko/qna/subscribers","subscription_url":"https://api.github.com/repos/valadzko/qna/subscription","commits_url":"https://api.github.com/repos/valadzko/qna/commits{/sha}","git_commits_url":"https://api.github.com/repos/valadzko/qna/git/commits{/sha}","comments_url":"https://api.github.com/repos/valadzko/qna/comments{/number}","issue_comment_url":"https://api.github.com/repos/valadzko/qna/issues/comments{/number}","contents_url":"https://api.github.com/repos/valadzko/qna/contents/{+path}","compare_url":"https://api.github.com/repos/valadzko/qna/compare/{base}...{head}","merges_url":"https://api.github.com/repos/valadzko/qna/merges","archive_url":"https://api.github.com/repos/valadzko/qna/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/valadzko/qna/downloads","issues_url":"https://api.github.com/repos/valadzko/qna/issues{/number}","pulls_url":"https://api.github.com/repos/valadzko/qna/pulls{/number}","milestones_url":"https://api.github.com/repos/valadzko/qna/milestones{/number}","notifications_url":"https://api.github.com/repos/valadzko/qna/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/valadzko/qna/labels{/name}","releases_url":"https://api.github.com/repos/valadzko/qna/releases{/id}","created_at":"2015-11-11T19:14:34Z","updated_at":"2015-11-11T19:38:20Z","pushed_at":"2015-11-14T10:01:29Z","git_url":"git://github.com/valadzko/qna.git","ssh_url":"git@github.com:valadzko/qna.git","clone_url":"https://github.com/valadzko/qna.git","svn_url":"https://github.com/valadzko/qna","homepage":null,"size":0,"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":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"valadzko:master","ref":"master","sha":"b5de21551457ad657c4ef923cfb351ad6c7618ef","user":{"login":"valadzko","id":12141346,"avatar_url":"https://avatars.githubusercontent.com/u/12141346?v=3","gravatar_id":"","url":"https://api.github.com/users/valadzko","html_url":"https://github.com/valadzko","followers_url":"https://api.github.com/users/valadzko/followers","following_url":"https://api.github.com/users/valadzko/following{/other_user}","gists_url":"https://api.github.com/users/valadzko/gists{/gist_id}","starred_url":"https://api.github.com/users/valadzko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/valadzko/subscriptions","organizations_url":"https://api.github.com/users/valadzko/orgs","repos_url":"https://api.github.com/users/valadzko/repos","events_url":"https://api.github.com/users/valadzko/events{/privacy}","received_events_url":"https://api.github.com/users/valadzko/received_events","type":"User","site_admin":false},"repo":{"id":46003913,"name":"qna","full_name":"valadzko/qna","owner":{"login":"valadzko","id":12141346,"avatar_url":"https://avatars.githubusercontent.com/u/12141346?v=3","gravatar_id":"","url":"https://api.github.com/users/valadzko","html_url":"https://github.com/valadzko","followers_url":"https://api.github.com/users/valadzko/followers","following_url":"https://api.github.com/users/valadzko/following{/other_user}","gists_url":"https://api.github.com/users/valadzko/gists{/gist_id}","starred_url":"https://api.github.com/users/valadzko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/valadzko/subscriptions","organizations_url":"https://api.github.com/users/valadzko/orgs","repos_url":"https://api.github.com/users/valadzko/repos","events_url":"https://api.github.com/users/valadzko/events{/privacy}","received_events_url":"https://api.github.com/users/valadzko/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/valadzko/qna","description":"","fork":false,"url":"https://api.github.com/repos/valadzko/qna","forks_url":"https://api.github.com/repos/valadzko/qna/forks","keys_url":"https://api.github.com/repos/valadzko/qna/keys{/key_id}","collaborators_url":"https://api.github.com/repos/valadzko/qna/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/valadzko/qna/teams","hooks_url":"https://api.github.com/repos/valadzko/qna/hooks","issue_events_url":"https://api.github.com/repos/valadzko/qna/issues/events{/number}","events_url":"https://api.github.com/repos/valadzko/qna/events","assignees_url":"https://api.github.com/repos/valadzko/qna/assignees{/user}","branches_url":"https://api.github.com/repos/valadzko/qna/branches{/branch}","tags_url":"https://api.github.com/repos/valadzko/qna/tags","blobs_url":"https://api.github.com/repos/valadzko/qna/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/valadzko/qna/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/valadzko/qna/git/refs{/sha}","trees_url":"https://api.github.com/repos/valadzko/qna/git/trees{/sha}","statuses_url":"https://api.github.com/repos/valadzko/qna/statuses/{sha}","languages_url":"https://api.github.com/repos/valadzko/qna/languages","stargazers_url":"https://api.github.com/repos/valadzko/qna/stargazers","contributors_url":"https://api.github.com/repos/valadzko/qna/contributors","subscribers_url":"https://api.github.com/repos/valadzko/qna/subscribers","subscription_url":"https://api.github.com/repos/valadzko/qna/subscription","commits_url":"https://api.github.com/repos/valadzko/qna/commits{/sha}","git_commits_url":"https://api.github.com/repos/valadzko/qna/git/commits{/sha}","comments_url":"https://api.github.com/repos/valadzko/qna/comments{/number}","issue_comment_url":"https://api.github.com/repos/valadzko/qna/issues/comments{/number}","contents_url":"https://api.github.com/repos/valadzko/qna/contents/{+path}","compare_url":"https://api.github.com/repos/valadzko/qna/compare/{base}...{head}","merges_url":"https://api.github.com/repos/valadzko/qna/merges","archive_url":"https://api.github.com/repos/valadzko/qna/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/valadzko/qna/downloads","issues_url":"https://api.github.com/repos/valadzko/qna/issues{/number}","pulls_url":"https://api.github.com/repos/valadzko/qna/pulls{/number}","milestones_url":"https://api.github.com/repos/valadzko/qna/milestones{/number}","notifications_url":"https://api.github.com/repos/valadzko/qna/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/valadzko/qna/labels{/name}","releases_url":"https://api.github.com/repos/valadzko/qna/releases{/id}","created_at":"2015-11-11T19:14:34Z","updated_at":"2015-11-11T19:38:20Z","pushed_at":"2015-11-14T10:01:29Z","git_url":"git://github.com/valadzko/qna.git","ssh_url":"git@github.com:valadzko/qna.git","clone_url":"https://github.com/valadzko/qna.git","svn_url":"https://github.com/valadzko/qna","homepage":null,"size":0,"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":1,"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/valadzko/qna/pulls/1"},"html":{"href":"https://github.com/valadzko/qna/pull/1"},"issue":{"href":"https://api.github.com/repos/valadzko/qna/issues/1"},"comments":{"href":"https://api.github.com/repos/valadzko/qna/issues/1/comments"},"review_comments":{"href":"https://api.github.com/repos/valadzko/qna/pulls/1/comments"},"review_comment":{"href":"https://api.github.com/repos/valadzko/qna/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/valadzko/qna/pulls/1/commits"},"statuses":{"href":"https://api.github.com/repos/valadzko/qna/statuses/2630c619ce70e66fb8ec50d0a4edbc6b13085f40"}}}}