refactor(cli): drop listeners without an id and name the source arguments

This commit is contained in:
Hugo Durand
2026-09-22 15:28:20 -04:00
parent f89bf66d84
commit a3a2a2e33a
4 changed files with 48 additions and 13 deletions
@@ -914,3 +914,21 @@ def test_a_truncated_listener_page_says_so(deploy_project: DeployProject) -> Non
assert result.exit_code != 0
assert "first 100" in result.output
def test_a_listener_without_an_id_is_ignored(deploy_project: DeployProject) -> None:
deploy_project.control_plane.listeners = [
{"compute_id": "broken", "compute_config": {"k8s_namespaces": ["agents"]}},
LISTENER,
]
result = deploy_project.run(
"--push-to", PUSH_REPOSITORY, host_url=CLOUD_CONTROL_PLANE_URL
)
assert result.exit_code == 0, result.output
assert deploy_project.control_plane.bodies[CREATE_DEPLOYMENT]["source_config"] == {
"resource_spec": {},
"listener_id": "listener-1",
"listener_config": {"k8s_namespace": "agents"},
}