mirror of
https://github.com/pewdiepie-archdaemon/odysseus.git
synced 2026-06-22 20:55:29 -04:00
fix(cookbook): harden remote serve host handling (#4345)
This commit is contained in:
@@ -36,10 +36,22 @@ def test_cookbook_submodules_resolve_visible_profile_selection():
|
||||
assert "_serverByVal(_envState.remoteServerKey || remoteHost)" in HWFIT
|
||||
assert "hk: _currentServerValue()" in HWFIT
|
||||
assert "sel.value = _currentServerValue();" in HWFIT
|
||||
assert "_serverByVal?.(_ssEl.value)" in SERVE
|
||||
assert "_serverByVal?.(select.value)" in SERVE
|
||||
assert "_serverByVal?.(val)" in SERVE
|
||||
assert "_serverByVal?.(_es.remoteServerKey || _es.remoteHost || '')" in SERVE
|
||||
assert "_serverByVal?.(_envState.remoteServerKey || _probeHost)" in SERVE
|
||||
assert "port: host ? (server?.port || _getPort(host) || '') : ''" in SERVE
|
||||
|
||||
|
||||
def test_serve_launch_preflights_use_selected_target_and_port():
|
||||
launch_target = "const launchTarget = _selectedServeTarget(panel);"
|
||||
assert launch_target in SERVE
|
||||
assert "const _hostStr = launchTarget.host || '';" in SERVE
|
||||
assert "const _probeHost = (launchTarget.host || '').trim();" in SERVE
|
||||
assert "if (launchTarget.port) _probeParams.set('ssh_port', launchTarget.port);" in SERVE
|
||||
assert "const _portHost = (launchTarget.host || '').trim();" in SERVE
|
||||
assert "StrictHostKeyChecking=no ${_sshPrefix(launchTarget.port)}${_portHost}" in SERVE
|
||||
assert "let serveHost = launchTarget.host || '';" in SERVE
|
||||
assert SERVE.index(launch_target) < SERVE.index("const _runningMod = await import('./cookbookRunning.js');")
|
||||
|
||||
|
||||
def test_running_tab_resolves_profile_key_not_first_host():
|
||||
|
||||
Reference in New Issue
Block a user