Add test for fish_config in browser modified

In particular
- test that it will return an error if the URL is invalid
- that the main page matches the index.html in git
- that "Enter" key will exit

Part of #11907
This commit is contained in:
Nahor
2025-10-06 11:52:02 -07:00
committed by Johannes Altmanninger
parent a00e6f8696
commit 65332eaacc
2 changed files with 62 additions and 1 deletions

View File

@@ -1544,7 +1544,10 @@ print("%sHit ENTER to stop.%s" % (ENTER_BOLD_MODE, EXIT_ATTRIBUTE_MODE))
def runThing():
if isMacOS10_12_5_OrLater():
if os.environ.get("BROWSER") == "true":
# Don't start a browser in this case (see issue #11926)
pass
elif isMacOS10_12_5_OrLater():
subprocess.check_call(["open", fileurl])
elif is_wsl():
cmd_path = find_executable("cmd.exe", COMMON_WSL_CMD_PATHS)