-
Notifications
You must be signed in to change notification settings - Fork 96
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove chrome's
--no-sandbox
from tests (#576)
Our tests included the `--no-sandbox` option for chrome. This seems to have been harmless until recently. On Windows, it now results in orphaned chrome processes which results in tests bogging and then, after a long, while failing. Removing `--no-sandbox` when running on Windows resolves the issue. The `--no-sandbox` option allows testing under a root user. Because we don't run tests under root on any OS or environment, I feel comfortable removing `--no-sandbox` across all OS testing. This change also includes new bb task `ps`, a bare-bones cross-platform way to report on running processes. This was useful while diagnosing the issue so I've left it in. I also switched from `babashka.process/destroy` to `babashka.process/destroy-tree` when killing a web driver process. This did not help with the Windows chrome orphan issue, but I expect it is generally a better way to go. Closes #572
- Loading branch information
Showing
12 changed files
with
47 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
(ns helper.ps | ||
;; noice! bb uses a modern JDK so we have ProcessHandle | ||
(:import (java.lang ProcessHandle))) | ||
|
||
(defn all-processes [] | ||
(for [p (-> (ProcessHandle/allProcesses) .iterator iterator-seq) | ||
:when (some-> p .info .command .isPresent) | ||
:let [info (.info p) | ||
command (-> info .command .get) | ||
arguments (when (-> info .arguments .isPresent) | ||
(->> info .arguments .get (into []))) | ||
start-instant (-> info .startInstant .get)]] | ||
{:pid (.pid p) | ||
:is-alive (.isAlive p) | ||
:start-instant start-instant | ||
:handle p | ||
:command command | ||
:arguments arguments})) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters