(t *testing.T)
| 883 | } |
| 884 | |
| 885 | func TestNilEngineConfig(t *testing.T) { |
| 886 | engines := []CodingAgentEngine{ |
| 887 | NewClaudeEngine(), |
| 888 | NewCodexEngine(), |
| 889 | } |
| 890 | |
| 891 | for _, engine := range engines { |
| 892 | t.Run(engine.GetID(), func(t *testing.T) { |
| 893 | // Should not panic when engineConfig is nil |
| 894 | workflowData := &WorkflowData{ |
| 895 | Name: "test-workflow", |
| 896 | } |
| 897 | steps := engine.GetExecutionSteps(workflowData, "test-log") |
| 898 | |
| 899 | // Engines should return at least one step |
| 900 | if len(steps) == 0 { |
| 901 | t.Errorf("Expected at least one step for engine %s, got none", engine.GetID()) |
| 902 | } |
| 903 | |
| 904 | // Check that the first step has some content |
| 905 | if len(steps) > 0 && len(steps[0]) == 0 { |
| 906 | t.Errorf("Expected non-empty step content for engine %s", engine.GetID()) |
| 907 | } |
| 908 | }) |
| 909 | } |
| 910 | } |
| 911 | |
| 912 | func TestEngineBareFieldExtraction(t *testing.T) { |
| 913 | compiler := NewCompiler() |
nothing calls this directly
no test coverage detected