Improve initialization in test_user

rust
Elnu 2 years ago
parent 04b4240e0f
commit d2758c852e

@ -255,10 +255,11 @@ mod tests {
use crate::User;
fn test_user(name: &str, discriminator: u16) -> User {
let mut user = User::default();
user.name = name.to_owned();
user.discriminator = discriminator;
user
User {
name: name.to_owned(),
discriminator,
..Default::default()
}
}
#[test]

Loading…
Cancel
Save