File: pyo3-0.27

package info (click to toggle)
rust-pythonize 0.28.0-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 232 kB
  • sloc: makefile: 2
file content (41 lines) | stat: -rw-r--r-- 1,344 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Index: pythonize/Cargo.toml
===================================================================
--- pythonize.orig/Cargo.toml
+++ pythonize/Cargo.toml
@@ -51,7 +51,7 @@ name = "test_with_serde_path_to_err"
 path = "tests/test_with_serde_path_to_err.rs"
 
 [dependencies.pyo3]
-version = "0.28"
+version = ">=0.27,<0.29"
 default-features = false
 
 [dependencies.serde]
@@ -69,7 +69,7 @@ default-features = false
 version = "1.0.2"
 
 [dev-dependencies.pyo3]
-version = "0.28"
+version = ">=0.27,<0.29"
 features = [
     "auto-initialize",
     "macros",
Index: pythonize/tests/test_with_serde_path_to_err.rs
===================================================================
--- pythonize.orig/tests/test_with_serde_path_to_err.rs
+++ pythonize/tests/test_with_serde_path_to_err.rs
@@ -100,10 +100,12 @@ fn test_de_invalid() {
         let err = serde_path_to_error::deserialize::<_, Root<String>>(de).unwrap_err();
 
         assert_eq!(err.path().to_string(), "root_map.nested_1.nested_key");
-        assert_eq!(
+        if err.to_string() != "root_map.nested_1.nested_key: unexpected type: 'int' object cannot be cast as 'str'" {
+          assert_eq!(
             err.to_string(),
             "root_map.nested_1.nested_key: unexpected type: 'int' object is not an instance of 'str'"
-        );
+          );
+        }
     })
 }