Skip to content
This repository has been archived by the owner on Mar 25, 2024. It is now read-only.

Commit

Permalink
Fix clippy warning
Browse files Browse the repository at this point in the history
  • Loading branch information
luke-biel committed Feb 10, 2021
1 parent d80e1c9 commit b0764f2
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions tests/test_value.rs
Expand Up @@ -29,6 +29,12 @@ fn test_digits() {

#[test]
fn test_into_deserializer() {
#[derive(Debug, Deserialize, PartialEq)]
struct Test {
first: String,
second: u32,
}

let value = serde_yaml::from_str::<Value>("xyz").unwrap();
let s = String::deserialize(value.into_deserializer()).unwrap();
assert_eq!(s, "xyz");
Expand All @@ -37,12 +43,6 @@ fn test_into_deserializer() {
let arr = Vec::<String>::deserialize(value.into_deserializer()).unwrap();
assert_eq!(arr, &["first", "second", "third"]);

#[derive(Debug, Deserialize, PartialEq)]
struct Test {
first: String,
second: u32,
}

let value = serde_yaml::from_str::<Value>("first: abc\nsecond: 99").unwrap();
let test = Test::deserialize(value.into_deserializer()).unwrap();
assert_eq!(
Expand Down

0 comments on commit b0764f2

Please sign in to comment.