()
| 235 | |
| 236 | #[test] |
| 237 | fn test_append() { |
| 238 | let gil = Python::acquire_gil(); |
| 239 | let py = gil.python(); |
| 240 | let v = vec![2, 3, 5, 7]; |
| 241 | let list = v.to_py_object(py); |
| 242 | let val = 42i32.to_py_object(py).into_object(); |
| 243 | assert_eq!(4, list.len(py)); |
| 244 | list.append(py, val); |
| 245 | assert_eq!(5, list.len(py)); |
| 246 | assert_eq!(42, list.get_item(py, 4).extract::<i32>(py).unwrap()); |
| 247 | } |
| 248 | |
| 249 | #[test] |
| 250 | fn test_iter() { |
nothing calls this directly
no test coverage detected