{"action":"created","comment":{"url":"https://api.github.com/repos/alexieze/test-guru/pulls/comments/178452643","pull_request_review_id":108513495,"id":178452643,"diff_hunk":"@@ -1,6 +1,56 @@\n class TestsController < ApplicationController\n \n-  def index\n-      render html: \"Main page!\"\n+  before_action :all\n+  before_action :find_test, only: [:show, :edit, :update, :destroy]\n+  before_action :test_params, only: [:create, :update]\n+\n+  def index; end\n+\n+  def edit; end\n+\n+  def show; end\n+\n+  def new\n+    @test = Test.new\n+  end\n+\n+  def create\n+    @test = Test.new(test_params)\n+    @test.user_id = 1\n+    if @test.save\n+      redirect_to tests_path(@tests)\n+    else\n+      render :new\n+    end\n+  end\n+\n+\n+\n+  def destroy\n+    @test.destroy\n+    redirect_to tests_path(@tests)","path":"app/controllers/tests_controller.rb","position":33,"original_position":33,"commit_id":"b7b944511664b9679084cb031ab5b6a4dd95494f","original_commit_id":"b7b944511664b9679084cb031ab5b6a4dd95494f","user":{"login":"vkurennov","id":968537,"avatar_url":"https://avatars3.githubusercontent.com/u/968537?v=4","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":"Для url-хелпера, ведущего на index ну нужно передавать параметр.","created_at":"2018-04-01T09:15:15Z","updated_at":"2018-04-01T09:15:25Z","html_url":"https://github.com/alexieze/test-guru/pull/7#discussion_r178452643","pull_request_url":"https://api.github.com/repos/alexieze/test-guru/pulls/7","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/alexieze/test-guru/pulls/comments/178452643"},"html":{"href":"https://github.com/alexieze/test-guru/pull/7#discussion_r178452643"},"pull_request":{"href":"https://api.github.com/repos/alexieze/test-guru/pulls/7"}}},"pull_request":{"url":"https://api.github.com/repos/alexieze/test-guru/pulls/7","id":178669951,"html_url":"https://github.com/alexieze/test-guru/pull/7","diff_url":"https://github.com/alexieze/test-guru/pull/7.diff","patch_url":"https://github.com/alexieze/test-guru/pull/7.patch","issue_url":"https://api.github.com/repos/alexieze/test-guru/issues/7","number":7,"state":"open","locked":false,"title":"DZ path 8","user":{"login":"alexieze","id":2096708,"avatar_url":"https://avatars1.githubusercontent.com/u/2096708?v=4","gravatar_id":"","url":"https://api.github.com/users/alexieze","html_url":"https://github.com/alexieze","followers_url":"https://api.github.com/users/alexieze/followers","following_url":"https://api.github.com/users/alexieze/following{/other_user}","gists_url":"https://api.github.com/users/alexieze/gists{/gist_id}","starred_url":"https://api.github.com/users/alexieze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexieze/subscriptions","organizations_url":"https://api.github.com/users/alexieze/orgs","repos_url":"https://api.github.com/users/alexieze/repos","events_url":"https://api.github.com/users/alexieze/events{/privacy}","received_events_url":"https://api.github.com/users/alexieze/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-03-31T07:04:52Z","updated_at":"2018-04-01T09:15:25Z","closed_at":null,"merged_at":null,"merge_commit_sha":"0988197dd1d7289bc1aa99aec0609b592b4202ee","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/alexieze/test-guru/pulls/7/commits","review_comments_url":"https://api.github.com/repos/alexieze/test-guru/pulls/7/comments","review_comment_url":"https://api.github.com/repos/alexieze/test-guru/pulls/comments{/number}","comments_url":"https://api.github.com/repos/alexieze/test-guru/issues/7/comments","statuses_url":"https://api.github.com/repos/alexieze/test-guru/statuses/b7b944511664b9679084cb031ab5b6a4dd95494f","head":{"label":"alexieze:Views","ref":"Views","sha":"b7b944511664b9679084cb031ab5b6a4dd95494f","user":{"login":"alexieze","id":2096708,"avatar_url":"https://avatars1.githubusercontent.com/u/2096708?v=4","gravatar_id":"","url":"https://api.github.com/users/alexieze","html_url":"https://github.com/alexieze","followers_url":"https://api.github.com/users/alexieze/followers","following_url":"https://api.github.com/users/alexieze/following{/other_user}","gists_url":"https://api.github.com/users/alexieze/gists{/gist_id}","starred_url":"https://api.github.com/users/alexieze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexieze/subscriptions","organizations_url":"https://api.github.com/users/alexieze/orgs","repos_url":"https://api.github.com/users/alexieze/repos","events_url":"https://api.github.com/users/alexieze/events{/privacy}","received_events_url":"https://api.github.com/users/alexieze/received_events","type":"User","site_admin":false},"repo":{"id":113870452,"name":"test-guru","full_name":"alexieze/test-guru","owner":{"login":"alexieze","id":2096708,"avatar_url":"https://avatars1.githubusercontent.com/u/2096708?v=4","gravatar_id":"","url":"https://api.github.com/users/alexieze","html_url":"https://github.com/alexieze","followers_url":"https://api.github.com/users/alexieze/followers","following_url":"https://api.github.com/users/alexieze/following{/other_user}","gists_url":"https://api.github.com/users/alexieze/gists{/gist_id}","starred_url":"https://api.github.com/users/alexieze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexieze/subscriptions","organizations_url":"https://api.github.com/users/alexieze/orgs","repos_url":"https://api.github.com/users/alexieze/repos","events_url":"https://api.github.com/users/alexieze/events{/privacy}","received_events_url":"https://api.github.com/users/alexieze/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/alexieze/test-guru","description":null,"fork":false,"url":"https://api.github.com/repos/alexieze/test-guru","forks_url":"https://api.github.com/repos/alexieze/test-guru/forks","keys_url":"https://api.github.com/repos/alexieze/test-guru/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alexieze/test-guru/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alexieze/test-guru/teams","hooks_url":"https://api.github.com/repos/alexieze/test-guru/hooks","issue_events_url":"https://api.github.com/repos/alexieze/test-guru/issues/events{/number}","events_url":"https://api.github.com/repos/alexieze/test-guru/events","assignees_url":"https://api.github.com/repos/alexieze/test-guru/assignees{/user}","branches_url":"https://api.github.com/repos/alexieze/test-guru/branches{/branch}","tags_url":"https://api.github.com/repos/alexieze/test-guru/tags","blobs_url":"https://api.github.com/repos/alexieze/test-guru/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alexieze/test-guru/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alexieze/test-guru/git/refs{/sha}","trees_url":"https://api.github.com/repos/alexieze/test-guru/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alexieze/test-guru/statuses/{sha}","languages_url":"https://api.github.com/repos/alexieze/test-guru/languages","stargazers_url":"https://api.github.com/repos/alexieze/test-guru/stargazers","contributors_url":"https://api.github.com/repos/alexieze/test-guru/contributors","subscribers_url":"https://api.github.com/repos/alexieze/test-guru/subscribers","subscription_url":"https://api.github.com/repos/alexieze/test-guru/subscription","commits_url":"https://api.github.com/repos/alexieze/test-guru/commits{/sha}","git_commits_url":"https://api.github.com/repos/alexieze/test-guru/git/commits{/sha}","comments_url":"https://api.github.com/repos/alexieze/test-guru/comments{/number}","issue_comment_url":"https://api.github.com/repos/alexieze/test-guru/issues/comments{/number}","contents_url":"https://api.github.com/repos/alexieze/test-guru/contents/{+path}","compare_url":"https://api.github.com/repos/alexieze/test-guru/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alexieze/test-guru/merges","archive_url":"https://api.github.com/repos/alexieze/test-guru/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alexieze/test-guru/downloads","issues_url":"https://api.github.com/repos/alexieze/test-guru/issues{/number}","pulls_url":"https://api.github.com/repos/alexieze/test-guru/pulls{/number}","milestones_url":"https://api.github.com/repos/alexieze/test-guru/milestones{/number}","notifications_url":"https://api.github.com/repos/alexieze/test-guru/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alexieze/test-guru/labels{/name}","releases_url":"https://api.github.com/repos/alexieze/test-guru/releases{/id}","deployments_url":"https://api.github.com/repos/alexieze/test-guru/deployments","created_at":"2017-12-11T14:42:46Z","updated_at":"2018-03-28T13:23:59Z","pushed_at":"2018-03-31T15:22:45Z","git_url":"git://github.com/alexieze/test-guru.git","ssh_url":"git@github.com:alexieze/test-guru.git","clone_url":"https://github.com/alexieze/test-guru.git","svn_url":"https://github.com/alexieze/test-guru","homepage":null,"size":59,"stargazers_count":1,"watchers_count":1,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":1,"default_branch":"master"}},"base":{"label":"alexieze:master","ref":"master","sha":"cde253919280b770b73896dbdd760ae692e4e047","user":{"login":"alexieze","id":2096708,"avatar_url":"https://avatars1.githubusercontent.com/u/2096708?v=4","gravatar_id":"","url":"https://api.github.com/users/alexieze","html_url":"https://github.com/alexieze","followers_url":"https://api.github.com/users/alexieze/followers","following_url":"https://api.github.com/users/alexieze/following{/other_user}","gists_url":"https://api.github.com/users/alexieze/gists{/gist_id}","starred_url":"https://api.github.com/users/alexieze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexieze/subscriptions","organizations_url":"https://api.github.com/users/alexieze/orgs","repos_url":"https://api.github.com/users/alexieze/repos","events_url":"https://api.github.com/users/alexieze/events{/privacy}","received_events_url":"https://api.github.com/users/alexieze/received_events","type":"User","site_admin":false},"repo":{"id":113870452,"name":"test-guru","full_name":"alexieze/test-guru","owner":{"login":"alexieze","id":2096708,"avatar_url":"https://avatars1.githubusercontent.com/u/2096708?v=4","gravatar_id":"","url":"https://api.github.com/users/alexieze","html_url":"https://github.com/alexieze","followers_url":"https://api.github.com/users/alexieze/followers","following_url":"https://api.github.com/users/alexieze/following{/other_user}","gists_url":"https://api.github.com/users/alexieze/gists{/gist_id}","starred_url":"https://api.github.com/users/alexieze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexieze/subscriptions","organizations_url":"https://api.github.com/users/alexieze/orgs","repos_url":"https://api.github.com/users/alexieze/repos","events_url":"https://api.github.com/users/alexieze/events{/privacy}","received_events_url":"https://api.github.com/users/alexieze/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/alexieze/test-guru","description":null,"fork":false,"url":"https://api.github.com/repos/alexieze/test-guru","forks_url":"https://api.github.com/repos/alexieze/test-guru/forks","keys_url":"https://api.github.com/repos/alexieze/test-guru/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alexieze/test-guru/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alexieze/test-guru/teams","hooks_url":"https://api.github.com/repos/alexieze/test-guru/hooks","issue_events_url":"https://api.github.com/repos/alexieze/test-guru/issues/events{/number}","events_url":"https://api.github.com/repos/alexieze/test-guru/events","assignees_url":"https://api.github.com/repos/alexieze/test-guru/assignees{/user}","branches_url":"https://api.github.com/repos/alexieze/test-guru/branches{/branch}","tags_url":"https://api.github.com/repos/alexieze/test-guru/tags","blobs_url":"https://api.github.com/repos/alexieze/test-guru/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alexieze/test-guru/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alexieze/test-guru/git/refs{/sha}","trees_url":"https://api.github.com/repos/alexieze/test-guru/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alexieze/test-guru/statuses/{sha}","languages_url":"https://api.github.com/repos/alexieze/test-guru/languages","stargazers_url":"https://api.github.com/repos/alexieze/test-guru/stargazers","contributors_url":"https://api.github.com/repos/alexieze/test-guru/contributors","subscribers_url":"https://api.github.com/repos/alexieze/test-guru/subscribers","subscription_url":"https://api.github.com/repos/alexieze/test-guru/subscription","commits_url":"https://api.github.com/repos/alexieze/test-guru/commits{/sha}","git_commits_url":"https://api.github.com/repos/alexieze/test-guru/git/commits{/sha}","comments_url":"https://api.github.com/repos/alexieze/test-guru/comments{/number}","issue_comment_url":"https://api.github.com/repos/alexieze/test-guru/issues/comments{/number}","contents_url":"https://api.github.com/repos/alexieze/test-guru/contents/{+path}","compare_url":"https://api.github.com/repos/alexieze/test-guru/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alexieze/test-guru/merges","archive_url":"https://api.github.com/repos/alexieze/test-guru/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alexieze/test-guru/downloads","issues_url":"https://api.github.com/repos/alexieze/test-guru/issues{/number}","pulls_url":"https://api.github.com/repos/alexieze/test-guru/pulls{/number}","milestones_url":"https://api.github.com/repos/alexieze/test-guru/milestones{/number}","notifications_url":"https://api.github.com/repos/alexieze/test-guru/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alexieze/test-guru/labels{/name}","releases_url":"https://api.github.com/repos/alexieze/test-guru/releases{/id}","deployments_url":"https://api.github.com/repos/alexieze/test-guru/deployments","created_at":"2017-12-11T14:42:46Z","updated_at":"2018-03-28T13:23:59Z","pushed_at":"2018-03-31T15:22:45Z","git_url":"git://github.com/alexieze/test-guru.git","ssh_url":"git@github.com:alexieze/test-guru.git","clone_url":"https://github.com/alexieze/test-guru.git","svn_url":"https://github.com/alexieze/test-guru","homepage":null,"size":59,"stargazers_count":1,"watchers_count":1,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":null,"forks":0,"open_issues":1,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/alexieze/test-guru/pulls/7"},"html":{"href":"https://github.com/alexieze/test-guru/pull/7"},"issue":{"href":"https://api.github.com/repos/alexieze/test-guru/issues/7"},"comments":{"href":"https://api.github.com/repos/alexieze/test-guru/issues/7/comments"},"review_comments":{"href":"https://api.github.com/repos/alexieze/test-guru/pulls/7/comments"},"review_comment":{"href":"https://api.github.com/repos/alexieze/test-guru/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/alexieze/test-guru/pulls/7/commits"},"statuses":{"href":"https://api.github.com/repos/alexieze/test-guru/statuses/b7b944511664b9679084cb031ab5b6a4dd95494f"}},"author_association":"OWNER"}}
{"actor":{"display_login":"vkurennov"}}