(obj: &Bound<'_, PyAny>, expected: &T, expected_json: &JsonValue)
| 674 | } |
| 675 | |
| 676 | fn test_de_with_obj<T>(obj: &Bound<'_, PyAny>, expected: &T, expected_json: &JsonValue) |
| 677 | where |
| 678 | T: de::DeserializeOwned + PartialEq + std::fmt::Debug, |
| 679 | { |
| 680 | let actual: T = depythonize(obj).unwrap(); |
| 681 | assert_eq!(&actual, expected); |
| 682 | |
| 683 | let actual_json: JsonValue = depythonize(obj).unwrap(); |
| 684 | assert_eq!(&actual_json, expected_json); |
| 685 | } |
| 686 | |
| 687 | #[test] |
| 688 | fn test_empty_struct() { |
no test coverage detected