From 6f0895fee11ce6ab266d861da74420804c7e01b6 Mon Sep 17 00:00:00 2001 From: Doug A Date: Tue, 5 Sep 2023 19:55:09 -0300 Subject: [PATCH] feat(interop-tests): add ability to run chromedriver tests on Windows When running on Windows OS, the command needs the `.cmd` extension in order to work. Pull-Request: #4456. --- interop-tests/src/bin/wasm_ping.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/interop-tests/src/bin/wasm_ping.rs b/interop-tests/src/bin/wasm_ping.rs index 20350170d59..83ed3c37465 100644 --- a/interop-tests/src/bin/wasm_ping.rs +++ b/interop-tests/src/bin/wasm_ping.rs @@ -103,7 +103,12 @@ async fn open_in_browser() -> Result<(Child, WebDriver)> { // start a webdriver process // currently only the chromedriver is supported as firefox doesn't // have support yet for the certhashes - let mut chrome = tokio::process::Command::new("chromedriver") + let chromedriver = if cfg!(windows) { + "chromedriver.cmd" + } else { + "chromedriver" + }; + let mut chrome = tokio::process::Command::new(chromedriver) .arg("--port=45782") .stdout(Stdio::piped()) .spawn()?;