Skip to content

Commit

Permalink
chore: fix linter issues
Browse files Browse the repository at this point in the history
Signed-off-by: Damien Cupif <[email protected]>
  • Loading branch information
dcupif committed Nov 5, 2024
1 parent 49cd327 commit 75d6149
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
1 change: 1 addition & 0 deletions pkg/ppm/bounds.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,5 +118,6 @@ func convertToDateTimeWithoutTimezone(bound time.Time) time.Time {
if err != nil {
return time.Time{}
}

return parsedTime
}
11 changes: 8 additions & 3 deletions pkg/ppm/checkpartition_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,15 @@ func TestCheckPartitions(t *testing.T) {

// Build mock for each partitions
for _, p := range partitions {
var tables []partition.Partition
var retentionTables []partition.Partition
var preprovisionedTables []partition.Partition
var (
tables []partition.Partition
retentionTables []partition.Partition
preprovisionedTables []partition.Partition
)

// Create retention partitions
forDate := time.Now()

switch p.Interval {
case partition.Daily:
retentionTables, _ = p.GetRetentionPartitions(forDate)
Expand All @@ -71,6 +74,7 @@ func TestCheckPartitions(t *testing.T) {
default:
t.Errorf("unuspported partition interval in retention table mock")
}

tables = append(tables, retentionTables...)

// Create current partition
Expand All @@ -92,6 +96,7 @@ func TestCheckPartitions(t *testing.T) {
default:
t.Errorf("unuspported partition interval in preprovisonned table mock")
}

tables = append(tables, preprovisionedTables...)

postgreSQLMock.On("GetColumnDataType", p.Schema, p.Table, p.PartitionKey).Return(postgresql.Date, nil).Once()
Expand Down

0 comments on commit 75d6149

Please sign in to comment.