Run go fmt

This commit is contained in:
Taras Kushnir
2026-02-13 12:54:10 +02:00
parent 07bf5f60a6
commit 0db0153337
5 changed files with 15 additions and 15 deletions
+5 -5
View File
@@ -17,11 +17,11 @@ func TestEnvConfigValueUpdate(t *testing.T) {
t.Parallel()
testCases := []struct {
name string
key common.ConfigKey
envValue string
expectedValue string
expectedError bool
name string
key common.ConfigKey
envValue string
expectedValue string
expectedError bool
}{
{"valid_key_with_value", common.StageKey, "production", "production", false},
{"valid_key_empty_value", common.StageKey, "", "", true},
+3 -3
View File
@@ -259,9 +259,9 @@ func TestMemoryTimeSeriesRetrievePropertyStatsByPeriodAllPeriods(t *testing.T) {
// Add records at various times to test different period aggregations
accessRecords := []*common.AccessRecord{
{OrgID: 1, PropertyID: 1, Timestamp: now.Add(-30 * time.Minute)}, // Today
{OrgID: 1, PropertyID: 1, Timestamp: now.Add(-2 * time.Hour)}, // Today
{OrgID: 1, PropertyID: 1, Timestamp: now.Add(-3 * 24 * time.Hour)}, // This week
{OrgID: 1, PropertyID: 1, Timestamp: now.Add(-30 * time.Minute)}, // Today
{OrgID: 1, PropertyID: 1, Timestamp: now.Add(-2 * time.Hour)}, // Today
{OrgID: 1, PropertyID: 1, Timestamp: now.Add(-3 * 24 * time.Hour)}, // This week
{OrgID: 1, PropertyID: 1, Timestamp: now.Add(-15 * 24 * time.Hour)}, // This month
}
ts.WriteAccessLogBatch(ctx, accessRecords)
+3 -3
View File
@@ -23,9 +23,9 @@ var (
)
const (
registerContentsTemplate = "login/register-contents.html"
userNameErrorMessage = "Name contains invalid characters."
emailAlreadyRegisteredError = "Such email is already registered. Login instead?"
registerContentsTemplate = "login/register-contents.html"
userNameErrorMessage = "Name contains invalid characters."
emailAlreadyRegisteredError = "Such email is already registered. Login instead?"
)
func (s *Server) getRegister(w http.ResponseWriter, r *http.Request) (*ViewModel, error) {
+3 -3
View File
@@ -522,9 +522,9 @@ func TestDeleteAccount(t *testing.T) {
}
type accountStatsSuiteResult struct {
user *dbgen.User
srv *http.ServeMux
cookie *http.Cookie
user *dbgen.User
srv *http.ServeMux
cookie *http.Cookie
}
func accountStatsSuite(t *testing.T, ctx context.Context) *accountStatsSuiteResult {
+1 -1
View File
@@ -1,8 +1,8 @@
package puzzle
import (
"encoding/binary"
"encoding/base64"
"encoding/binary"
randv2 "math/rand/v2"
"testing"
"time"