Skip to content

Commit

Permalink
fix lint/test
Browse files Browse the repository at this point in the history
  • Loading branch information
jack-r-warren committed Jul 25, 2024
1 parent d6ba3aa commit 8a6f023
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions sherlock/internal/api/sherlock/chart_releases_v3_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -346,6 +346,7 @@ func (s *handlerSuite) TestChartReleaseV3_toModel() {
}

func Test_chartReleaseFromModel(t *testing.T) {
config.LoadTestConfig()
now := time.Now()
type args struct {
model models.ChartRelease
Expand Down
1 change: 1 addition & 0 deletions sherlock/internal/api/sherlock/environments_v3_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -311,6 +311,7 @@ func (s *handlerSuite) TestEnvironmentV3_toModel() {
}

func Test_environmentFromModel(t *testing.T) {
config.LoadTestConfig()
now := time.Now()
nowString := utils.TimePtrToISO8601(&now)
nowTimeParsedAgain, err := utils.ISO8601PtrToTime(nowString)
Expand Down
3 changes: 3 additions & 0 deletions sherlock/internal/oidc_models/test_helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ func (h TestClientHelper) GenerateClient(db *gorm.DB) (clientID string, clientSe

clientSecretSalt := make([]byte, 32)
_, err = rand.Read(clientSecretSalt)
if err != nil {
return "", "", err
}

testClientHashIterations := 1_000 // Low low low value!!! Needs to be 210_000+ in production, this just makes tests run faster
clientSecretHash := pbkdf2.Key([]byte(clientSecret), clientSecretSalt, testClientHashIterations, 32, sha512.New)
Expand Down

0 comments on commit 8a6f023

Please sign in to comment.