octokit/octokit.net — pull request #365 by pmacn (2014-02-09 08:31:43+00:00)
Title: Nonfunctioning tests

So, since I knew I had spotted at least a handful of tests that were not actually doing any Asserts I figured I would sit down and see if I couldn't track down most of them. And here's the result.

Most of these are un-awaited `AssertEx.Throw`.
In most cases these were replaced with Assert.Throw. Whenever the method was not
async and there was no reason to await to get to the exception.
In the remaining cases they were simply awaited. I also took the liberty of making the lambdas not async whenever possible since awaiting is already handled inside `AssertEx.Throw`.

Other ones were validations on `Substitute` objects that were missing the `Receive()`. And some cases of missing receives that were trying to validate the wrong call.

If we'd rather have the `Assert.Throw` calls changed into awaited `AssertEx.Throw` I should be able to do that fairly quickly. Go Team Regex!

Most of these tests were really only covering argument Ensures. And all but one was functioning as expected. I've made one change where a method was getting the wrong Uri.