Computes the path to the source file `name`.
(name: &str)
| 32 | |
| 33 | /// Computes the path to the source file `name`. |
| 34 | pub(super) fn src_path(name: &str) -> PathBuf { |
| 35 | let dir = |
| 36 | Path::new(env!("CARGO_MANIFEST_DIR")).parent().expect("Failed to get parent directory"); |
| 37 | |
| 38 | // Sanity-check that we landed in the right location. |
| 39 | assert!(dir.join("Cargo.lock").exists()); |
| 40 | |
| 41 | dir.join(name) |
| 42 | } |
| 43 | |
| 44 | /// A parsed test case from a golden data file. |
| 45 | #[derive(Debug, Eq, PartialEq)] |
no outgoing calls
no test coverage detected