Skip to content

The cross-harness, self-improving memory layer for AI agents. Join our community: https://discord.com/invite/zdNChS2fBu

test(sentinel): tolerate CRLF in the batch-size check

shukieshaha04fb31ff6b7
diff --git a/cli/beacon/internal/endpoint/sentinel/sentinel_test.go b/cli/beacon/internal/endpoint/sentinel/sentinel_test.go
index cc9faaea..96c3ee5d 100644
--- a/cli/beacon/internal/endpoint/sentinel/sentinel_test.go
+++ b/cli/beacon/internal/endpoint/sentinel/sentinel_test.go
@@ -271,7 +271,8 @@ func TestKQLAssetsMentionSentinelTableAndValidation(t *testing.T) {
// 10 MB by default, so a busy flush would lose a whole batch to 413s.
func TestVectorBatchesFitTheLogsIngestionLimit(t *testing.T) {
vector := mustRead("pack/vector.toml.tmpl")
- match := regexp.MustCompile(`(?m)^max_bytes = (\d+)$`).FindStringSubmatch(vector)
+ // \r? because Windows checkouts carry CRLF, and (?m)$ matches only before \n.
+ match := regexp.MustCompile(`(?m)^max_bytes = (\d+)\r?$`).FindStringSubmatch(vector)
if match == nil {
t.Fatal("vector.toml does not cap batch.max_bytes, so the sink batches up to 10 MB")
}