public virtual void TestInvalidUri2() { WebResource r = Resource(); string responseStr = string.Empty; try { responseStr = r.QueryParam("user.name", Users[round]).Accept(MediaType.ApplicationJson ).Get <string>(); NUnit.Framework.Assert.Fail("should have thrown exception on invalid uri"); } catch (UniformInterfaceException ue) { ClientResponse response = ue.GetResponse(); NUnit.Framework.Assert.AreEqual(ClientResponse.Status.NotFound, response.GetClientResponseStatus ()); WebServicesTestUtils.CheckStringMatch("error string exists and shouldn't", string.Empty , responseStr); } }