@@ -1002,62 +1002,6 @@ func TestAddCheckpointTrailer_ExistingTrailers(t *testing.T) {
10021002 }
10031003}
10041004
1005- func TestCheckpointInfo_JSONRoundTrip (t * testing.T ) {
1006- original := CheckpointInfo {
1007- CheckpointID : "a1b2c3d4e5f6" ,
1008- SessionID : "session-123" ,
1009- CreatedAt : time .Date (2025 , 12 , 2 , 10 , 0 , 0 , 0 , time .UTC ),
1010- CheckpointsCount : 5 ,
1011- FilesTouched : []string {"file1.go" , "file2.go" },
1012- }
1013-
1014- data , err := json .Marshal (original )
1015- if err != nil {
1016- t .Fatalf ("json.Marshal() error = %v" , err )
1017- }
1018-
1019- var loaded CheckpointInfo
1020- if err := json .Unmarshal (data , & loaded ); err != nil {
1021- t .Fatalf ("json.Unmarshal() error = %v" , err )
1022- }
1023-
1024- if loaded .CheckpointID != original .CheckpointID {
1025- t .Errorf ("CheckpointID = %q, want %q" , loaded .CheckpointID , original .CheckpointID )
1026- }
1027- if loaded .SessionID != original .SessionID {
1028- t .Errorf ("SessionID = %q, want %q" , loaded .SessionID , original .SessionID )
1029- }
1030- }
1031-
1032- func TestSessionState_JSONRoundTrip (t * testing.T ) {
1033- original := SessionState {
1034- SessionID : "session-123" ,
1035- BaseCommit : "abc123def456" ,
1036- StartedAt : time .Date (2025 , 12 , 2 , 10 , 0 , 0 , 0 , time .UTC ),
1037- StepCount : 10 ,
1038- }
1039-
1040- data , err := json .Marshal (original )
1041- if err != nil {
1042- t .Fatalf ("json.Marshal() error = %v" , err )
1043- }
1044-
1045- var loaded SessionState
1046- if err := json .Unmarshal (data , & loaded ); err != nil {
1047- t .Fatalf ("json.Unmarshal() error = %v" , err )
1048- }
1049-
1050- if loaded .SessionID != original .SessionID {
1051- t .Errorf ("SessionID = %q, want %q" , loaded .SessionID , original .SessionID )
1052- }
1053- if loaded .BaseCommit != original .BaseCommit {
1054- t .Errorf ("BaseCommit = %q, want %q" , loaded .BaseCommit , original .BaseCommit )
1055- }
1056- if loaded .StepCount != original .StepCount {
1057- t .Errorf ("StepCount = %d, want %d" , loaded .StepCount , original .StepCount )
1058- }
1059- }
1060-
10611005func TestShadowStrategy_GetCheckpointLog_WithCheckpointID (t * testing.T ) {
10621006 // This test verifies that GetCheckpointLog correctly uses the checkpoint ID
10631007 // to look up the log. Since getCheckpointLog requires a full git setup
0 commit comments