Operation IDs whose system actor matches `actor_name`.
(&self, actor_name: &str)
| 230 | |
| 231 | /// Operation IDs whose system actor matches `actor_name`. |
| 232 | fn adoption_operation_ids(&self, actor_name: &str) -> Vec<String> { |
| 233 | let log = atomic_ok( |
| 234 | self.root(), |
| 235 | self.home(), |
| 236 | &["op", "log", "--json", "-n", "60"], |
| 237 | ); |
| 238 | let value: serde_json::Value = serde_json::from_str(&log).expect("op log json"); |
| 239 | value["entries"] |
| 240 | .as_array() |
| 241 | .expect("log entries") |
| 242 | .iter() |
| 243 | .filter(|entry| { |
| 244 | entry["actor"]["kind"] == "system" && entry["actor"]["name"] == actor_name |
| 245 | }) |
| 246 | .filter_map(|entry| entry["id"].as_str().map(str::to_string)) |
| 247 | .collect() |
| 248 | } |
| 249 | |
| 250 | /// The decoded bytes of a content-addressed change (contents, hunks, and |
| 251 | /// hashed metadata) for store-level assertions. |
no test coverage detected