This commit is contained in:
Shreyas Goenka 2025-02-03 04:20:24 +01:00
parent 427c755ea7
commit b83e57621e
No known key found for this signature in database
GPG Key ID: 92A07DF49CCB0622
4 changed files with 5 additions and 5 deletions

View File

@ -36,7 +36,7 @@ var (
// In order to debug CLI running under acceptance test, set this to full subtest name, e.g. "bundle/variables/empty"
// Then install your breakpoints and click "debug test" near TestAccept in VSCODE.
// example: var SingleTest = "bundle/variables/empty"
var SingleTest = "libs/telemetry/upload"
var SingleTest = ""
// If enabled, instead of compiling and running CLI externally, we'll start in-process server that accepts and runs
// CLI commands. The $CLI in test scripts is a helper that just forwards command-line arguments to this server (see bin/callserver.py).
@ -44,7 +44,7 @@ var SingleTest = "libs/telemetry/upload"
var InprocessMode bool
func init() {
flag.BoolVar(&InprocessMode, "inprocess", false, "Run CLI in the same process as test (for debugging)")
flag.BoolVar(&InprocessMode, "inprocess", SingleTest != "", "Run CLI in the same process as test (for debugging)")
flag.BoolVar(&KeepTmp, "keeptmp", false, "Do not delete TMP directory after run")
flag.BoolVar(&NoRepl, "norepl", false, "Do not apply any replacements (for debugging)")
}

View File

@ -2,6 +2,6 @@ panic: runtime error: index out of range [1] with length 1
goroutine 1 [running]:
main.main()
/Users/shreyas.goenka/cli/main.go:18 +0x154
/Users/shreyas.goenka/cli/main.go:22 +0x1b0
Exit code: 2

View File

@ -1 +1 @@
{"method":"POST","path":"/telemetry-ext","body":{"uploadTime":"[UNIX_TIME_MILLIS]","items":[],"protoLogs":["{\"frontend_log_event_id\":\"[UUID]\",\"entry\":{\"databricks_cli_log\":{\"execution_context\":{\"cmd_exec_id\":\"[UUID]\",\"version\":\"$DEV_VERSION\",\"command\":\"telemetry_dummy\",\"operating_system\":\"darwin\",\"execution_time_ms\":1},\"cli_test_event\":{\"name\":\"VALUE1\"}}}}","{\"frontend_log_event_id\":\"[UUID]\",\"entry\":{\"databricks_cli_log\":{\"execution_context\":{\"cmd_exec_id\":\"[UUID]\",\"version\":\"$DEV_VERSION\",\"command\":\"telemetry_dummy\",\"operating_system\":\"darwin\",\"execution_time_ms\":1},\"cli_test_event\":{\"name\":\"VALUE2\"}}}}"]}}
{"method":"POST","path":"/telemetry-ext","body":{"uploadTime":"[UNIX_TIME_MILLIS]","items":[],"protoLogs":["{\"frontend_log_event_id\":\"[UUID]\",\"entry\":{\"databricks_cli_log\":{\"execution_context\":{\"cmd_exec_id\":\"[UUID]\",\"version\":\"$DEV_VERSION\",\"command\":\"telemetry_dummy\",\"operating_system\":\"darwin\"},\"cli_test_event\":{\"name\":\"VALUE1\"}}}}","{\"frontend_log_event_id\":\"[UUID]\",\"entry\":{\"databricks_cli_log\":{\"execution_context\":{\"cmd_exec_id\":\"[UUID]\",\"version\":\"$DEV_VERSION\",\"command\":\"telemetry_dummy\",\"operating_system\":\"darwin\"},\"cli_test_event\":{\"name\":\"VALUE2\"}}}}"]}}

View File

@ -14,7 +14,7 @@ import (
var OverwriteMode = false
func init() {
flag.BoolVar(&OverwriteMode, "update", true, "Overwrite golden files")
flag.BoolVar(&OverwriteMode, "update", false, "Overwrite golden files")
}
func ReadFile(t testutil.TestingT, ctx context.Context, filename string) string {