Keep supervised log entries verbatim

This commit is contained in:
npc0-hue
2026-09-02 12:22:41 +08:00
parent 386a295f20
commit 8de49f2dd3
5 changed files with 5 additions and 11 deletions
+2 -2
View File
@@ -392,7 +392,7 @@ func TestWorkerSpoolHooksUseRegisteredSession(t *testing.T) {
if err != nil {
t.Fatalf("pending logs: %v", err)
}
if len(logs) != 1 || logs[0].RunEndpointID != "run-test" || logs[0].SessionToken != "session-token" || logs[0].StreamKey != "game.console.stdout" || logs[0].Entries[0].Line != "started password=hidden" || logs[0].Entries[0].Redacted {
if len(logs) != 1 || logs[0].RunEndpointID != "run-test" || logs[0].SessionToken != "session-token" || logs[0].StreamKey != "game.console.stdout" || logs[0].Entries[0].Line != "started password=hidden" {
t.Fatalf("unexpected spooled logs: %+v", logs)
}
chunks, err := artifactQueue.Pending()
@@ -623,7 +623,7 @@ func TestSpoolLogSinkKeepsSequencesIndependentAndDurable(t *testing.T) {
func TestSessionLogBatchClientOverridesSpooledIdentityAndChecksum(t *testing.T) {
recorder := &recordingDurableLogClient{}
entry := protocol.LogEntry{Seq: 7, Timestamp: workerTestTime(), Level: "info", Line: "server ready", Redacted: false}
entry := protocol.LogEntry{Seq: 7, Timestamp: workerTestTime(), Level: "info", Line: "server ready"}
batch := protocol.LogBatchIngestRequest{
RunEndpointID: "old-endpoint",
SessionToken: "old-token",