public async Task ResetUserPassword_GivenAValidAndExistingUserId_ShouldResetUserPassword() { var request = await DoPostRequest("api/user/resetuserpassword", ADMIN_USER_ID.ToString()); request.EnsureSuccessStatusCode(); var response = GetStructResult <bool>(await request.Content.ReadAsStringAsync()); Assert.AreEqual(HttpStatusCode.OK, request.StatusCode); Assert.IsTrue(response); }
public async Task EditUser_GivenAValidUserDataToEdit_ShouldEditTheUserData() { var userdata = new UserViewDto { Id = ADMIN_USER_ID.ToString(), Email = "*****@*****.**", UserName = "******", }; var request = await DoPostRequest("api/user/edituser", userdata); request.EnsureSuccessStatusCode(); var response = GetStructResult <bool>(await request.Content.ReadAsStringAsync()); Assert.AreEqual(HttpStatusCode.OK, request.StatusCode); Assert.IsTrue(response); }