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

Method new

rust/src/firefox.rs:84–101  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

82
83impl FirefoxManager {
84 pub fn new() -> Result<Box<Self>, Error> {
85 let browser_name = FIREFOX_NAME;
86 let driver_name = GECKODRIVER_NAME;
87 let config = ManagerConfig::default(browser_name, driver_name);
88 let default_timeout = config.timeout.to_owned();
89 let default_proxy = &config.proxy;
90 let (tx, rx): (Sender<String>, Receiver<String>) = mpsc::channel();
91 Ok(Box::new(FirefoxManager {
92 browser_name,
93 driver_name,
94 http_client: create_http_client(default_timeout, default_proxy)?,
95 config,
96 log: Logger::new(),
97 tx,
98 rx,
99 download_browser: false,
100 }))
101 }
102
103 fn create_firefox_details_url(&self, endpoint: &str) -> String {
104 format!("{}{}", FIREFOX_DETAILS_URL, endpoint)

Callers

nothing calls this directly

Calls 1

create_http_clientFunction · 0.85

Tested by

no test coverage detected