public void ShouldForLoopMoreThan10Users() { UserVoice.Client client = getSignedClient(); UserVoice.Collection users = client.LoginAsOwner().GetCollection("/api/v1/users"); int times = 3; for (int i = 0; i < users.Count(); i++) { if (--times <= 0) { break; } //Console.WriteLine("User: " + users[i]); } AssertTrue(users.Count() > 10); }
public void ShouldGetMoreThan10Users() { UserVoice.Client client = getSignedClient(); UserVoice.Collection users = client.LoginAsOwner().GetCollection("/api/v1/users"); int times = 3; foreach (var k in users) { if (--times <= 0) { break; } //Console.WriteLine("User: " + k); } AssertTrue(users.Count() > 10); }
public void ShouldGetOnly3Users() { UserVoice.Client client = getSignedClient(); UserVoice.Collection users = client.LoginAsOwner().GetCollection("/api/v1/users", 3); AssertEqual(3, users.Count()); }
public void ShouldGetNoUsers() { UserVoice.Client client = getSignedClient(); UserVoice.Collection users = client.LoginAsOwner().GetCollection("/api/v1/users/search?query=from:[email protected]"); AssertEqual(0, users.Count()); }