Skip to content
Closed
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
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Cloud = false
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Error: invalid -L "8080": expected LOCAL:REMOTE ports, e.g. 8080:10080
Error: invalid -L "8080:8080": remote port must be between 10000 and 65535
Error: required flag(s) "forward" not set
8 changes: 8 additions & 0 deletions acceptance/cmd/sandbox/port-forward/invalid-forward/script
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Malformed -L specs are rejected before any API call, so no [[Server]] stub is needed.
musterr $CLI sandbox port-forward happy-panda-1234 -L 8080

# Remote ports outside 10000-65535 are refused up front.
musterr $CLI sandbox port-forward happy-panda-1234 -L 8080:8080

# At least one -L is required.
musterr $CLI sandbox port-forward happy-panda-1234
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Cloud = false
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Error: no default sandbox configured — run `databricks sandbox create` to provision one, or `databricks sandbox default <id>` to point at an existing sandbox
2 changes: 2 additions & 0 deletions acceptance/cmd/sandbox/port-forward/no-default/script
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Without a sandbox ID the default sandbox is used; the fresh home has none.
musterr $CLI sandbox port-forward -L 0:10080
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Cloud = false
1 change: 1 addition & 0 deletions acceptance/cmd/sandbox/port-forward/not-found/output.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Error: no sandbox named "no-such-box" — `databricks sandbox list` shows available IDs
1 change: 1 addition & 0 deletions acceptance/cmd/sandbox/port-forward/not-found/script
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
musterr $CLI sandbox port-forward no-such-box -L 0:10080
4 changes: 4 additions & 0 deletions acceptance/cmd/sandbox/port-forward/not-found/test.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[[Server]]
Pattern = "GET /api/2.0/lakebox/sandboxes/no-such-box"
Response.StatusCode = 404
Response.Body = '{"error_code": "NOT_FOUND", "message": "Sandbox not found"}'
Loading