Method
fetch_bytes
(
&mut self,
spec: &str,
_expected_hash: Option<[u8; 32]>,
)
Source from the content-addressed store, hash-verified
| 119 | } |
| 120 | |
| 121 | fn fetch_bytes( |
| 122 | &mut self, |
| 123 | spec: &str, |
| 124 | _expected_hash: Option<[u8; 32]>, |
| 125 | ) -> Result<Vec<u8>, String> { |
| 126 | // In-memory map; the parser still runs its hash check downstream. |
| 127 | match self.state.borrow().bytes.get(spec) { |
| 128 | Some(b) => Ok(b.clone()), |
| 129 | None => Err(format!("module '{}' integrity verification not supported by this resolver", spec)), |
| 130 | } |
| 131 | } |
| 132 | } |
| 133 | |
| 134 | impl TestResolver { |
Callers
nothing calls this directly
Tested by
no test coverage detected