{"action":"created","issue":{"url":"https://api.github.com/repos/seattlerb/minitest/issues/566","labels_url":"https://api.github.com/repos/seattlerb/minitest/issues/566/labels{/name}","comments_url":"https://api.github.com/repos/seattlerb/minitest/issues/566/comments","events_url":"https://api.github.com/repos/seattlerb/minitest/issues/566/events","html_url":"https://github.com/seattlerb/minitest/pull/566","id":95828569,"number":566,"title":"Bug in Mock#verify","user":{"login":"pithub","id":5896616,"avatar_url":"https://avatars.githubusercontent.com/u/5896616?v=3","gravatar_id":"","url":"https://api.github.com/users/pithub","html_url":"https://github.com/pithub","followers_url":"https://api.github.com/users/pithub/followers","following_url":"https://api.github.com/users/pithub/following{/other_user}","gists_url":"https://api.github.com/users/pithub/gists{/gist_id}","starred_url":"https://api.github.com/users/pithub/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pithub/subscriptions","organizations_url":"https://api.github.com/users/pithub/orgs","repos_url":"https://api.github.com/users/pithub/repos","events_url":"https://api.github.com/users/pithub/events{/privacy}","received_events_url":"https://api.github.com/users/pithub/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"zenspider","id":9832,"avatar_url":"https://avatars.githubusercontent.com/u/9832?v=3","gravatar_id":"","url":"https://api.github.com/users/zenspider","html_url":"https://github.com/zenspider","followers_url":"https://api.github.com/users/zenspider/followers","following_url":"https://api.github.com/users/zenspider/following{/other_user}","gists_url":"https://api.github.com/users/zenspider/gists{/gist_id}","starred_url":"https://api.github.com/users/zenspider/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zenspider/subscriptions","organizations_url":"https://api.github.com/users/zenspider/orgs","repos_url":"https://api.github.com/users/zenspider/repos","events_url":"https://api.github.com/users/zenspider/events{/privacy}","received_events_url":"https://api.github.com/users/zenspider/received_events","type":"User","site_admin":false},"milestone":null,"comments":18,"created_at":"2015-07-18T14:13:17Z","updated_at":"2015-11-16T20:39:46Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/seattlerb/minitest/pulls/566","html_url":"https://github.com/seattlerb/minitest/pull/566","diff_url":"https://github.com/seattlerb/minitest/pull/566.diff","patch_url":"https://github.com/seattlerb/minitest/pull/566.patch"},"body":"I noticed a bug in `Mock#verify`:\r\n\r\n```ruby\r\nmock = Minitest::Mock.new\r\nmock.expect :foo, nil, [:bar]\r\nmock.expect :foo, nil, [:bar]\r\nmock.foo :bar\r\nmock.verify\r\n```\r\n\r\ndoesn't raise a `MockExpectationError`. Here's a fix consisting of the following commits:\r\n\r\n* **add failing test for bug** - the test specifies an error message which is not optimal, but matches the current implementation (see below)\r\n* **fix bug**\r\n* **specify better error messages in tests** - improved the expected error messages (at least in my eyes) - _this has an effect on an existing test!_\r\n* **fix tests** - since the history of actual calls isn't needed anymore for the new error messages, some code could be removed\r\n* **fix method rdoc of expect** - the documentation didn't describe the current behavior"},"comment":{"url":"https://api.github.com/repos/seattlerb/minitest/issues/comments/157162704","html_url":"https://github.com/seattlerb/minitest/pull/566#issuecomment-157162704","issue_url":"https://api.github.com/repos/seattlerb/minitest/issues/566","id":157162704,"user":{"login":"pithub","id":5896616,"avatar_url":"https://avatars.githubusercontent.com/u/5896616?v=3","gravatar_id":"","url":"https://api.github.com/users/pithub","html_url":"https://github.com/pithub","followers_url":"https://api.github.com/users/pithub/followers","following_url":"https://api.github.com/users/pithub/following{/other_user}","gists_url":"https://api.github.com/users/pithub/gists{/gist_id}","starred_url":"https://api.github.com/users/pithub/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pithub/subscriptions","organizations_url":"https://api.github.com/users/pithub/orgs","repos_url":"https://api.github.com/users/pithub/repos","events_url":"https://api.github.com/users/pithub/events{/privacy}","received_events_url":"https://api.github.com/users/pithub/received_events","type":"User","site_admin":false},"created_at":"2015-11-16T20:39:46Z","updated_at":"2015-11-16T20:39:46Z","body":"@zenspider @zamith I think there's too much confusion about this by now. Should I create a new pull request, based on the current version of minitest, consisting only of the former commits\r\n* [add failing test for bug](https://github.com/pithub/minitest/commit/22fef2ba752c92dfdc0af3dd0fe70cc9e81ce54f)\r\n* [fix bug](https://github.com/pithub/minitest/commit/21504b4fbb2a49a78e4837ebc424c050478c80b5)\r\n\r\nor change and rebase this pull request accordingly?"}}