(scope: ViewScopeLabel, parent: Option<&str>, own: &[&str])
| 193 | use super::*; |
| 194 | |
| 195 | fn snap(scope: ViewScopeLabel, parent: Option<&str>, own: &[&str]) -> ViewSnapshot { |
| 196 | ViewSnapshot::new( |
| 197 | scope, |
| 198 | parent.map(|s| s.to_string()), |
| 199 | vec![], |
| 200 | own.iter().map(|s| s.to_string()).collect(), |
| 201 | "SETID".to_string(), |
| 202 | own.last().map(|_| "MERKLE".to_string()), |
| 203 | ) |
| 204 | } |
| 205 | |
| 206 | #[test] |
| 207 | fn content_key_is_deterministic_and_bytes_roundtrip() { |