summaryrefslogtreecommitdiff
path: root/internal/executor/preamble_test.go
blob: 984f78653ff680148570d86cb61d724d9ab9da79 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
package executor

import (
	"strings"
	"testing"
)

func TestPlanningPreamble_ContainsFinalSummarySection(t *testing.T) {
	if !strings.Contains(planningPreamble, "## Final Summary (mandatory)") {
		t.Error("planningPreamble missing '## Final Summary (mandatory)' heading")
	}
}

func TestPlanningPreamble_SummaryUsesFileEnvVar(t *testing.T) {
	if !strings.Contains(planningPreamble, "CLAUDOMATOR_SUMMARY_FILE") {
		t.Error("planningPreamble should instruct agent to write summary to $CLAUDOMATOR_SUMMARY_FILE")
	}
}

func TestPlanningPreamble_SummaryInstructsEchoToFile(t *testing.T) {
	if !strings.Contains(planningPreamble, `"$CLAUDOMATOR_SUMMARY_FILE"`) {
		t.Error("planningPreamble should show example of writing to $CLAUDOMATOR_SUMMARY_FILE via echo")
	}
}