{"action":"created","comment":{"url":"https://api.github.com/repos/mikecm1141/connect_four/pulls/comments/202560711","pull_request_review_id":137284984,"id":202560711,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwMjU2MDcxMQ==","diff_hunk":"@@ -76,16 +76,185 @@ def test_it_can_let_computer_take_a_turn\n     assert_equal expected, actual\n   end\n \n-  def test_it_can_evaluate_win_or_loss_vertical_line\n+  def test_it_tracks_last_move\n     game = Game.new\n \n-    game.drop_piece('A', :player1)\n-    game.drop_piece('A', :player1)\n-    game.drop_piece('A', :player1)\n-    game.drop_piece('A', :player1)\n+    game.drop_piece(:A, :player1)\n+    game.drop_piece(:A, :player1)\n+    game.drop_piece(:A, :player1)\n \n-    expected = 'Congratulations, you have won Connect Four!'\n-    actual = game.evaluate_board(:player1)\n+    expected = { column: :A, position: 3, player: :player1 }\n+    actual = game.last_move\n+\n+    assert_equal expected, actual\n+  end\n+\n+  def test_it_checks_to_the_left\n+    game = Game.new\n+\n+    game.drop_piece(:A, :player1)\n+    game.drop_piece(:B, :player2)\n+    game.drop_piece(:C, :player2)\n+    game.drop_piece(:D, :player2)\n+\n+    expected = 3\n+    actual = game.check_left + 1\n+\n+    assert_equal expected, actual\n+  end\n+\n+  def test_it_checks_to_the_right\n+    game = Game.new\n+\n+    game.drop_piece(:D, :player1)\n+    game.drop_piece(:C, :player2)\n+    game.drop_piece(:B, :player2)\n+    game.drop_piece(:A, :player2)\n+\n+    expected = 3\n+    actual = game.check_right + 1\n+\n+    assert_equal expected, actual\n+  end\n+\n+  def test_it_checks_horizontally\n+    game = Game.new\n+\n+    game.drop_piece(:D, :player2)\n+    game.drop_piece(:C, :player2)\n+    game.drop_piece(:A, :player2)\n+    game.drop_piece(:B, :player2)\n+\n+    game.evaluate_board\n+\n+    expected = :gameover\n+    actual = game.status\n+\n+    assert_equal expected, actual\n+  end\n+\n+  def test_it_checks_downward\n+    game = Game.new\n+\n+    game.drop_piece(:A, :player1)\n+    game.drop_piece(:A, :player1)\n+    game.drop_piece(:A, :player1)\n+\n+    expected = 3\n+    actual = game.verify_downwards\n+\n+    assert_equal expected, actual\n+  end\n+\n+  def test_it_checks_up_right\n+    game = Game.new\n+\n+    game.drop_piece(:B, :player1)\n+    game.drop_piece(:B, :player1)\n+    game.drop_piece(:C, :player1)\n+    game.drop_piece(:C, :player1)\n+    game.drop_piece(:C, :player1)\n+    game.drop_piece(:D, :player1)\n+    game.drop_piece(:D, :player1)\n+    game.drop_piece(:D, :player1)\n+    game.drop_piece(:D, :player1)\n+    game.drop_piece(:A, :player1)\n+\n+    expected = 4\n+    actual = game.check_right_up + 1\n+\n+    assert_equal expected, actual\n+  end\n+\n+  def test_it_checks_left_down\n+    game = Game.new\n+\n+    game.drop_piece(:A, :player1)\n+    game.drop_piece(:B, :player1)\n+    game.drop_piece(:B, :player1)\n+    game.drop_piece(:C, :player1)\n+    game.drop_piece(:C, :player1)\n+    game.drop_piece(:C, :player1)\n+\n+    expected = 3\n+    actual = game.check_left_down + 1\n+\n+    assert_equal expected, actual\n+  end\n+\n+  def test_it_checks_forward_diagonally","path":"test/game_test.rb","position":153,"original_position":153,"commit_id":"ad8ce08f76c17ebb86404fd2fcdc59773606d485","original_commit_id":"ad8ce08f76c17ebb86404fd2fcdc59773606d485","user":{"login":"houndci-bot","id":6697940,"node_id":"MDQ6VXNlcjY2OTc5NDA=","avatar_url":"https://avatars0.githubusercontent.com/u/6697940?v=4","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":"Metrics/MethodLength: Method has too many lines. [15/10]","created_at":"2018-07-16T00:49:41Z","updated_at":"2018-07-16T00:49:43Z","html_url":"https://github.com/mikecm1141/connect_four/pull/10#discussion_r202560711","pull_request_url":"https://api.github.com/repos/mikecm1141/connect_four/pulls/10","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/mikecm1141/connect_four/pulls/comments/202560711"},"html":{"href":"https://github.com/mikecm1141/connect_four/pull/10#discussion_r202560711"},"pull_request":{"href":"https://api.github.com/repos/mikecm1141/connect_four/pulls/10"}}},"pull_request":{"url":"https://api.github.com/repos/mikecm1141/connect_four/pulls/10","id":201524380,"node_id":"MDExOlB1bGxSZXF1ZXN0MjAxNTI0Mzgw","html_url":"https://github.com/mikecm1141/connect_four/pull/10","diff_url":"https://github.com/mikecm1141/connect_four/pull/10.diff","patch_url":"https://github.com/mikecm1141/connect_four/pull/10.patch","issue_url":"https://api.github.com/repos/mikecm1141/connect_four/issues/10","number":10,"state":"closed","locked":false,"title":"Win conditions2","user":{"login":"mikecm1141","id":27649011,"node_id":"MDQ6VXNlcjI3NjQ5MDEx","avatar_url":"https://avatars1.githubusercontent.com/u/27649011?v=4","gravatar_id":"","url":"https://api.github.com/users/mikecm1141","html_url":"https://github.com/mikecm1141","followers_url":"https://api.github.com/users/mikecm1141/followers","following_url":"https://api.github.com/users/mikecm1141/following{/other_user}","gists_url":"https://api.github.com/users/mikecm1141/gists{/gist_id}","starred_url":"https://api.github.com/users/mikecm1141/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikecm1141/subscriptions","organizations_url":"https://api.github.com/users/mikecm1141/orgs","repos_url":"https://api.github.com/users/mikecm1141/repos","events_url":"https://api.github.com/users/mikecm1141/events{/privacy}","received_events_url":"https://api.github.com/users/mikecm1141/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-07-16T00:49:33Z","updated_at":"2018-07-16T00:49:43Z","closed_at":"2018-07-16T00:49:42Z","merged_at":"2018-07-16T00:49:42Z","merge_commit_sha":"8b31aea1863876cc8941fed7948b0b6bf11e20d7","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/mikecm1141/connect_four/pulls/10/commits","review_comments_url":"https://api.github.com/repos/mikecm1141/connect_four/pulls/10/comments","review_comment_url":"https://api.github.com/repos/mikecm1141/connect_four/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mikecm1141/connect_four/issues/10/comments","statuses_url":"https://api.github.com/repos/mikecm1141/connect_four/statuses/ad8ce08f76c17ebb86404fd2fcdc59773606d485","head":{"label":"mikecm1141:win_conditions2","ref":"win_conditions2","sha":"ad8ce08f76c17ebb86404fd2fcdc59773606d485","user":{"login":"mikecm1141","id":27649011,"node_id":"MDQ6VXNlcjI3NjQ5MDEx","avatar_url":"https://avatars1.githubusercontent.com/u/27649011?v=4","gravatar_id":"","url":"https://api.github.com/users/mikecm1141","html_url":"https://github.com/mikecm1141","followers_url":"https://api.github.com/users/mikecm1141/followers","following_url":"https://api.github.com/users/mikecm1141/following{/other_user}","gists_url":"https://api.github.com/users/mikecm1141/gists{/gist_id}","starred_url":"https://api.github.com/users/mikecm1141/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikecm1141/subscriptions","organizations_url":"https://api.github.com/users/mikecm1141/orgs","repos_url":"https://api.github.com/users/mikecm1141/repos","events_url":"https://api.github.com/users/mikecm1141/events{/privacy}","received_events_url":"https://api.github.com/users/mikecm1141/received_events","type":"User","site_admin":false},"repo":{"id":140869296,"node_id":"MDEwOlJlcG9zaXRvcnkxNDA4NjkyOTY=","name":"connect_four","full_name":"mikecm1141/connect_four","owner":{"login":"mikecm1141","id":27649011,"node_id":"MDQ6VXNlcjI3NjQ5MDEx","avatar_url":"https://avatars1.githubusercontent.com/u/27649011?v=4","gravatar_id":"","url":"https://api.github.com/users/mikecm1141","html_url":"https://github.com/mikecm1141","followers_url":"https://api.github.com/users/mikecm1141/followers","following_url":"https://api.github.com/users/mikecm1141/following{/other_user}","gists_url":"https://api.github.com/users/mikecm1141/gists{/gist_id}","starred_url":"https://api.github.com/users/mikecm1141/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikecm1141/subscriptions","organizations_url":"https://api.github.com/users/mikecm1141/orgs","repos_url":"https://api.github.com/users/mikecm1141/repos","events_url":"https://api.github.com/users/mikecm1141/events{/privacy}","received_events_url":"https://api.github.com/users/mikecm1141/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mikecm1141/connect_four","description":null,"fork":false,"url":"https://api.github.com/repos/mikecm1141/connect_four","forks_url":"https://api.github.com/repos/mikecm1141/connect_four/forks","keys_url":"https://api.github.com/repos/mikecm1141/connect_four/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mikecm1141/connect_four/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mikecm1141/connect_four/teams","hooks_url":"https://api.github.com/repos/mikecm1141/connect_four/hooks","issue_events_url":"https://api.github.com/repos/mikecm1141/connect_four/issues/events{/number}","events_url":"https://api.github.com/repos/mikecm1141/connect_four/events","assignees_url":"https://api.github.com/repos/mikecm1141/connect_four/assignees{/user}","branches_url":"https://api.github.com/repos/mikecm1141/connect_four/branches{/branch}","tags_url":"https://api.github.com/repos/mikecm1141/connect_four/tags","blobs_url":"https://api.github.com/repos/mikecm1141/connect_four/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mikecm1141/connect_four/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mikecm1141/connect_four/git/refs{/sha}","trees_url":"https://api.github.com/repos/mikecm1141/connect_four/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mikecm1141/connect_four/statuses/{sha}","languages_url":"https://api.github.com/repos/mikecm1141/connect_four/languages","stargazers_url":"https://api.github.com/repos/mikecm1141/connect_four/stargazers","contributors_url":"https://api.github.com/repos/mikecm1141/connect_four/contributors","subscribers_url":"https://api.github.com/repos/mikecm1141/connect_four/subscribers","subscription_url":"https://api.github.com/repos/mikecm1141/connect_four/subscription","commits_url":"https://api.github.com/repos/mikecm1141/connect_four/commits{/sha}","git_commits_url":"https://api.github.com/repos/mikecm1141/connect_four/git/commits{/sha}","comments_url":"https://api.github.com/repos/mikecm1141/connect_four/comments{/number}","issue_comment_url":"https://api.github.com/repos/mikecm1141/connect_four/issues/comments{/number}","contents_url":"https://api.github.com/repos/mikecm1141/connect_four/contents/{+path}","compare_url":"https://api.github.com/repos/mikecm1141/connect_four/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mikecm1141/connect_four/merges","archive_url":"https://api.github.com/repos/mikecm1141/connect_four/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mikecm1141/connect_four/downloads","issues_url":"https://api.github.com/repos/mikecm1141/connect_four/issues{/number}","pulls_url":"https://api.github.com/repos/mikecm1141/connect_four/pulls{/number}","milestones_url":"https://api.github.com/repos/mikecm1141/connect_four/milestones{/number}","notifications_url":"https://api.github.com/repos/mikecm1141/connect_four/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mikecm1141/connect_four/labels{/name}","releases_url":"https://api.github.com/repos/mikecm1141/connect_four/releases{/id}","deployments_url":"https://api.github.com/repos/mikecm1141/connect_four/deployments","created_at":"2018-07-13T16:24:22Z","updated_at":"2018-07-15T20:36:42Z","pushed_at":"2018-07-16T00:49:42Z","git_url":"git://github.com/mikecm1141/connect_four.git","ssh_url":"git@github.com:mikecm1141/connect_four.git","clone_url":"https://github.com/mikecm1141/connect_four.git","svn_url":"https://github.com/mikecm1141/connect_four","homepage":null,"size":23,"stargazers_count":0,"watchers_count":0,"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":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"mikecm1141:master","ref":"master","sha":"731a72df2c93bd876ae336a7ea7a32565d53bb0b","user":{"login":"mikecm1141","id":27649011,"node_id":"MDQ6VXNlcjI3NjQ5MDEx","avatar_url":"https://avatars1.githubusercontent.com/u/27649011?v=4","gravatar_id":"","url":"https://api.github.com/users/mikecm1141","html_url":"https://github.com/mikecm1141","followers_url":"https://api.github.com/users/mikecm1141/followers","following_url":"https://api.github.com/users/mikecm1141/following{/other_user}","gists_url":"https://api.github.com/users/mikecm1141/gists{/gist_id}","starred_url":"https://api.github.com/users/mikecm1141/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikecm1141/subscriptions","organizations_url":"https://api.github.com/users/mikecm1141/orgs","repos_url":"https://api.github.com/users/mikecm1141/repos","events_url":"https://api.github.com/users/mikecm1141/events{/privacy}","received_events_url":"https://api.github.com/users/mikecm1141/received_events","type":"User","site_admin":false},"repo":{"id":140869296,"node_id":"MDEwOlJlcG9zaXRvcnkxNDA4NjkyOTY=","name":"connect_four","full_name":"mikecm1141/connect_four","owner":{"login":"mikecm1141","id":27649011,"node_id":"MDQ6VXNlcjI3NjQ5MDEx","avatar_url":"https://avatars1.githubusercontent.com/u/27649011?v=4","gravatar_id":"","url":"https://api.github.com/users/mikecm1141","html_url":"https://github.com/mikecm1141","followers_url":"https://api.github.com/users/mikecm1141/followers","following_url":"https://api.github.com/users/mikecm1141/following{/other_user}","gists_url":"https://api.github.com/users/mikecm1141/gists{/gist_id}","starred_url":"https://api.github.com/users/mikecm1141/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikecm1141/subscriptions","organizations_url":"https://api.github.com/users/mikecm1141/orgs","repos_url":"https://api.github.com/users/mikecm1141/repos","events_url":"https://api.github.com/users/mikecm1141/events{/privacy}","received_events_url":"https://api.github.com/users/mikecm1141/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mikecm1141/connect_four","description":null,"fork":false,"url":"https://api.github.com/repos/mikecm1141/connect_four","forks_url":"https://api.github.com/repos/mikecm1141/connect_four/forks","keys_url":"https://api.github.com/repos/mikecm1141/connect_four/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mikecm1141/connect_four/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mikecm1141/connect_four/teams","hooks_url":"https://api.github.com/repos/mikecm1141/connect_four/hooks","issue_events_url":"https://api.github.com/repos/mikecm1141/connect_four/issues/events{/number}","events_url":"https://api.github.com/repos/mikecm1141/connect_four/events","assignees_url":"https://api.github.com/repos/mikecm1141/connect_four/assignees{/user}","branches_url":"https://api.github.com/repos/mikecm1141/connect_four/branches{/branch}","tags_url":"https://api.github.com/repos/mikecm1141/connect_four/tags","blobs_url":"https://api.github.com/repos/mikecm1141/connect_four/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mikecm1141/connect_four/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mikecm1141/connect_four/git/refs{/sha}","trees_url":"https://api.github.com/repos/mikecm1141/connect_four/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mikecm1141/connect_four/statuses/{sha}","languages_url":"https://api.github.com/repos/mikecm1141/connect_four/languages","stargazers_url":"https://api.github.com/repos/mikecm1141/connect_four/stargazers","contributors_url":"https://api.github.com/repos/mikecm1141/connect_four/contributors","subscribers_url":"https://api.github.com/repos/mikecm1141/connect_four/subscribers","subscription_url":"https://api.github.com/repos/mikecm1141/connect_four/subscription","commits_url":"https://api.github.com/repos/mikecm1141/connect_four/commits{/sha}","git_commits_url":"https://api.github.com/repos/mikecm1141/connect_four/git/commits{/sha}","comments_url":"https://api.github.com/repos/mikecm1141/connect_four/comments{/number}","issue_comment_url":"https://api.github.com/repos/mikecm1141/connect_four/issues/comments{/number}","contents_url":"https://api.github.com/repos/mikecm1141/connect_four/contents/{+path}","compare_url":"https://api.github.com/repos/mikecm1141/connect_four/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mikecm1141/connect_four/merges","archive_url":"https://api.github.com/repos/mikecm1141/connect_four/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mikecm1141/connect_four/downloads","issues_url":"https://api.github.com/repos/mikecm1141/connect_four/issues{/number}","pulls_url":"https://api.github.com/repos/mikecm1141/connect_four/pulls{/number}","milestones_url":"https://api.github.com/repos/mikecm1141/connect_four/milestones{/number}","notifications_url":"https://api.github.com/repos/mikecm1141/connect_four/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mikecm1141/connect_four/labels{/name}","releases_url":"https://api.github.com/repos/mikecm1141/connect_four/releases{/id}","deployments_url":"https://api.github.com/repos/mikecm1141/connect_four/deployments","created_at":"2018-07-13T16:24:22Z","updated_at":"2018-07-15T20:36:42Z","pushed_at":"2018-07-16T00:49:42Z","git_url":"git://github.com/mikecm1141/connect_four.git","ssh_url":"git@github.com:mikecm1141/connect_four.git","clone_url":"https://github.com/mikecm1141/connect_four.git","svn_url":"https://github.com/mikecm1141/connect_four","homepage":null,"size":23,"stargazers_count":0,"watchers_count":0,"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":0,"license":null,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mikecm1141/connect_four/pulls/10"},"html":{"href":"https://github.com/mikecm1141/connect_four/pull/10"},"issue":{"href":"https://api.github.com/repos/mikecm1141/connect_four/issues/10"},"comments":{"href":"https://api.github.com/repos/mikecm1141/connect_four/issues/10/comments"},"review_comments":{"href":"https://api.github.com/repos/mikecm1141/connect_four/pulls/10/comments"},"review_comment":{"href":"https://api.github.com/repos/mikecm1141/connect_four/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mikecm1141/connect_four/pulls/10/commits"},"statuses":{"href":"https://api.github.com/repos/mikecm1141/connect_four/statuses/ad8ce08f76c17ebb86404fd2fcdc59773606d485"}},"author_association":"OWNER"}}
{"actor":{"display_login":"houndci-bot"}}