public void AdminExist() { string name = ""; var rdata = r.GetAll(); var udata = u.GetAll(); var usradmin = 0; var roleadmin = 0; foreach (var item in rdata) { if (item.Role_Name == "Admin") { usradmin = 1; name = "Admin"; } } Assert.IsTrue(name == "Admin"); }