Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions logger/logger_test.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
package logger

import "testing"
import (
"testing"

import "github.com/sirupsen/logrus"
"github.com/sirupsen/logrus"
)

func TestLogLevel(t *testing.T) {
tests := map[string]logrus.Level{
Expand Down
3 changes: 2 additions & 1 deletion models/campaign_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package models

import (
"fmt"
"strconv"
"testing"
"time"

Expand Down Expand Up @@ -156,7 +157,7 @@ func setupCampaignDependencies(b *testing.B, size int) {
group := Group{Name: "Test Group"}
// Create a large group of 5000 members
for i := 0; i < size; i++ {
group.Targets = append(group.Targets, Target{BaseRecipient: BaseRecipient{Email: fmt.Sprintf("test%d@example.com", i), FirstName: "User", LastName: fmt.Sprintf("%d", i)}})
group.Targets = append(group.Targets, Target{BaseRecipient: BaseRecipient{Email: fmt.Sprintf("test%d@example.com", i), FirstName: "User", LastName: strconv.Itoa(i)}})
}
group.UserId = 1
err := PostGroup(&group)
Expand Down
5 changes: 3 additions & 2 deletions models/group_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package models

import (
"fmt"
"strconv"
"testing"

"github.com/jinzhu/gorm"
Expand Down Expand Up @@ -183,7 +184,7 @@ func benchmarkPostGroup(b *testing.B, iter, size int) {
g.Targets = append(g.Targets, Target{
BaseRecipient: BaseRecipient{
FirstName: "User",
LastName: fmt.Sprintf("%d", i),
LastName: strconv.Itoa(i),
Email: fmt.Sprintf("test-%d@test.com", i),
},
})
Expand All @@ -206,7 +207,7 @@ func benchmarkPutGroup(b *testing.B, iter, size int) {
g.Targets = append(g.Targets, Target{
BaseRecipient: BaseRecipient{
FirstName: "User",
LastName: fmt.Sprintf("%d", i),
LastName: strconv.Itoa(i),
Email: fmt.Sprintf("test-%d@test.com", i),
},
})
Expand Down