Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 0 additions & 29 deletions tests/smoketests/sdk/test_async_devbox.py
Original file line number Diff line number Diff line change
Expand Up @@ -437,35 +437,6 @@ async def test_create_ssh_key(self, async_sdk_client: AsyncRunloopSDK) -> None:
finally:
await devbox.shutdown()

@pytest.mark.timeout(TWO_MINUTE_TIMEOUT)
async def test_create_tunnel_deprecated(self, async_sdk_client: AsyncRunloopSDK) -> None:
"""Test creating a tunnel (deprecated - now creates v2 tunnel).

Note: The deprecated create_tunnel endpoint now creates v2 Portal tunnels
which cannot be removed. They remain active until the devbox is stopped.
Use enable_tunnel for creating v2 tunnels instead.
"""
devbox = await async_sdk_client.devbox.create(
name=unique_name("sdk-async-devbox-tunnel"),
launch_parameters={"resource_size_request": "SMALL", "keep_alive_time_seconds": 60 * 5},
)

try:
# Create tunnel (now creates v2 Portal tunnel)
with pytest.warns(DeprecationWarning, match="create_tunnel is deprecated"):
tunnel = await devbox.net.create_tunnel(port=8080)
assert tunnel is not None
assert tunnel.url is not None
assert tunnel.port == 8080
assert tunnel.devbox_id == devbox.id

# Verify tunnel persists in devbox info (v2 tunnels cannot be removed)
info = await devbox.get_info()
assert info.tunnel is not None
assert info.tunnel.tunnel_key is not None
finally:
await devbox.shutdown()

@pytest.mark.timeout(TWO_MINUTE_TIMEOUT)
async def test_create_with_tunnel_param(self, async_sdk_client: AsyncRunloopSDK) -> None:
"""Test creating a devbox with tunnel configuration in create params."""
Expand Down
29 changes: 0 additions & 29 deletions tests/smoketests/sdk/test_devbox.py
Original file line number Diff line number Diff line change
Expand Up @@ -434,35 +434,6 @@ def test_create_ssh_key(self, sdk_client: RunloopSDK) -> None:
finally:
devbox.shutdown()

@pytest.mark.timeout(TWO_MINUTE_TIMEOUT)
def test_create_tunnel_deprecated(self, sdk_client: RunloopSDK) -> None:
"""Test creating a tunnel (deprecated - now creates v2 tunnel).

Note: The deprecated create_tunnel endpoint now creates v2 Portal tunnels
which cannot be removed. They remain active until the devbox is stopped.
Use enable_tunnel for creating v2 tunnels instead.
"""
devbox = sdk_client.devbox.create(
name=unique_name("sdk-devbox-tunnel"),
launch_parameters={"resource_size_request": "SMALL", "keep_alive_time_seconds": 60 * 5},
)

try:
# Create tunnel (now creates v2 Portal tunnel)
with pytest.warns(DeprecationWarning, match="create_tunnel is deprecated"):
tunnel = devbox.net.create_tunnel(port=8080)
assert tunnel is not None
assert tunnel.url is not None
assert tunnel.port == 8080
assert tunnel.devbox_id == devbox.id

# Verify tunnel persists in devbox info (v2 tunnels cannot be removed)
info = devbox.get_info()
assert info.tunnel is not None
assert info.tunnel.tunnel_key is not None
finally:
devbox.shutdown()

@pytest.mark.timeout(TWO_MINUTE_TIMEOUT)
def test_create_with_tunnel_param(self, sdk_client: RunloopSDK) -> None:
"""Test creating a devbox with tunnel configuration in create params."""
Expand Down