Skip to main content

set_default_stdin_reader

Function set_default_stdin_reader 

Source
pub fn set_default_stdin_reader(reader: Arc<dyn StdinReader + Send + Sync>)
Expand description

Installs a process-global stdin reader that DefaultStdin (and therefore StdinSource::new) will delegate to until reset_default_stdin_reader is called.

Intended for test harnesses. Tests using this must run serially (e.g. via #[serial]) because the override is process-global.