1
use serde::{Deserialize, Serialize};
2

            
3
8
#[derive(Debug, Serialize, Deserialize, PartialEq, Eq)]
4
struct Borrowed<'a> {
5
    value: &'a str,
6
}
7

            
8
const BORROWED: &str = "Borrowed(value: \"test\")";
9

            
10
#[test]
11
4
fn borrowed_str() {
12
4
    assert_eq!(
13
4
        ron::de::from_str(BORROWED).ok(),
14
4
        Some(Borrowed { value: "test" })
15
4
    );
16
4
}