MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / get_cache_path

Method get_cache_path

rust/src/lib.rs:1650–1666  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

1648 }
1649
1650 fn get_cache_path(&self) -> Result<Option<PathBuf>, Error> {
1651 let path = Path::new(&self.get_config().cache_path);
1652 match create_path_if_not_exists(path) {
1653 Ok(_) => {
1654 let canon_path = self.canonicalize_path(path.to_path_buf());
1655 Ok(Some(Path::new(&canon_path).to_path_buf()))
1656 }
1657 Err(err) => {
1658 self.get_logger().warn(format!(
1659 "Cache folder ({}) cannot be created: {}",
1660 path.display(),
1661 err
1662 ));
1663 Ok(None)
1664 }
1665 }
1666 }
1667
1668 fn set_cache_path(&mut self, cache_path: String) {
1669 if !cache_path.is_empty() {

Callers 15

download_browserMethod · 0.80
setupMethod · 0.80
statsMethod · 0.80

Implementers 8

edge.rsrust/src/edge.rs
iexplorer.rsrust/src/iexplorer.rs
safaritp.rsrust/src/safaritp.rs
electron.rsrust/src/electron.rs
chrome.rsrust/src/chrome.rs
firefox.rsrust/src/firefox.rs
grid.rsrust/src/grid.rs
safari.rsrust/src/safari.rs

Calls 5

canonicalize_pathMethod · 0.80
get_configMethod · 0.45
warnMethod · 0.45
get_loggerMethod · 0.45

Tested by

no test coverage detected