diff --git a/cmd/evaluate_all_command_test.go b/cmd/evaluate_all_command_test.go index 36147245..ace8fa44 100644 --- a/cmd/evaluate_all_command_test.go +++ b/cmd/evaluate_all_command_test.go @@ -13,6 +13,7 @@ func TestCreateEvaluateAllCommand(t *testing.T) { if cmd == nil { t.Fatal("createEvaluateAllCommand returned nil") + return } // Test basic command properties diff --git a/cmd/evaluate_sequence_command_test.go b/cmd/evaluate_sequence_command_test.go index 539b4a20..b8e91175 100644 --- a/cmd/evaluate_sequence_command_test.go +++ b/cmd/evaluate_sequence_command_test.go @@ -13,6 +13,7 @@ func TestCreateEvaluateSequenceCommand(t *testing.T) { if cmd == nil { t.Fatal("createEvaluateSequenceCommand returned nil") + return } // Test basic command properties diff --git a/cmd/root_test.go b/cmd/root_test.go index c141f800..79ea4125 100644 --- a/cmd/root_test.go +++ b/cmd/root_test.go @@ -195,6 +195,7 @@ func TestNew(t *testing.T) { if rootCmd == nil { t.Fatal("New() returned nil") + return } // Test basic command properties diff --git a/pkg/yqlib/expression_parser_test.go b/pkg/yqlib/expression_parser_test.go index 5f970ff9..6632057c 100644 --- a/pkg/yqlib/expression_parser_test.go +++ b/pkg/yqlib/expression_parser_test.go @@ -95,6 +95,7 @@ func TestParserSingleOperation(t *testing.T) { test.AssertResultComplex(t, nil, err) if result == nil { t.Fatal("Expected non-nil result for single operation") + return } if result.Operation == nil { t.Fatal("Expected operation to be set") diff --git a/yq_test.go b/yq_test.go index 7c031215..978fada3 100644 --- a/yq_test.go +++ b/yq_test.go @@ -14,6 +14,7 @@ func TestMainFunction(t *testing.T) { cmd := command.New() if cmd == nil { t.Fatal("command.New() returned nil") + return } if cmd.Use != "yq" { @@ -99,6 +100,7 @@ func TestMainFunctionExecution(t *testing.T) { // the command structure is correct and can be configured if cmd == nil { t.Fatal("Command should not be nil") + return } if cmd.Use != "yq" {