Skip to content

Commit ab09080

Browse files
committed
test: add DeleteImportedSessions method to mock repositories
Fixed failing tests by implementing missing DeleteImportedSessions method in all mock SessionRepository implementations: - mockSessionRepo (services_test.go) - stubSessionRepo (compose_service_test.go) - mockSessionRepoForPerformance (performance/usecase/service_test.go) This resolves compilation errors in CI/CD pipeline where tests failed with "missing method DeleteImportedSessions" error.
1 parent b78c64a commit ab09080

File tree

3 files changed

+12
-0
lines changed

3 files changed

+12
-0
lines changed

internal/features/performance/usecase/service_test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -624,6 +624,10 @@ func (m *mockSessionRepoForPerformance) ClearAllSessions(ctx context.Context) er
624624
return nil
625625
}
626626

627+
func (m *mockSessionRepoForPerformance) DeleteImportedSessions(ctx context.Context) error {
628+
return nil
629+
}
630+
627631
type mockFrameRepoForPerformance struct{}
628632

629633
func (m *mockFrameRepoForPerformance) AppendFrame(ctx context.Context, sessionID string, f domain.Frame) error {

internal/usecase/compose_service_test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,10 @@ func (s *stubSessionRepo) ClearAllSessions(ctx context.Context) error {
9999
return nil
100100
}
101101

102+
func (s *stubSessionRepo) DeleteImportedSessions(ctx context.Context) error {
103+
return nil
104+
}
105+
102106
type stubFrameRepo struct{}
103107

104108
func (stubFrameRepo) AppendFrame(ctx context.Context, sessionID string, f domain.Frame) error {

internal/usecase/services_test.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,10 @@ func (m *mockSessionRepo) ClearAllSessions(ctx context.Context) error {
5757
return nil
5858
}
5959

60+
func (m *mockSessionRepo) DeleteImportedSessions(ctx context.Context) error {
61+
return nil
62+
}
63+
6064
func (m *mockSessionRepo) AddSpoolFile(ctx context.Context, sessionID string, path string) {}
6165

6266
type mockFrameRepo struct {

0 commit comments

Comments
 (0)