Skip to content

Commit

Permalink
Update message
Browse files Browse the repository at this point in the history
  • Loading branch information
oinume committed Feb 6, 2021
1 parent 93bc68b commit 5fdf917
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions backend/modeltest/modeltest_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,20 @@ func TestNewTodo(t *testing.T) {
createdAt := time.Date(2021, 1, 1, 0, 1, 30, 0, time.UTC)
tests := map[string]struct {
setter func(*model.Todo)
want *model.Todo
want *model.Todo
}{
"normal": {
setter: func (todo *model.Todo) {
setter: func(todo *model.Todo) {
todo.ID = "aaa"
todo.Title = "aaa"
todo.Completed = 1
todo.CreatedAt =createdAt
todo.CreatedAt = createdAt
todo.UpdatedAt = createdAt
},
want: &model.Todo{
ID: "aaa",
ID: "aaa",
Completed: 1,
Title: "aaa",
Title: "aaa",
CreatedAt: createdAt,
UpdatedAt: createdAt,
},
Expand All @@ -34,7 +34,7 @@ func TestNewTodo(t *testing.T) {
for name, tt := range tests {
t.Run(name, func(t *testing.T) {
if got := NewTodo(tt.setter); !reflect.DeepEqual(got, tt.want) {
t.Errorf("NewTodo() = %v, want %v", got, tt.want)
t.Errorf("NewTodo(): got=%v, want=%v", got, tt.want)
}
})
}
Expand Down

0 comments on commit 5fdf917

Please sign in to comment.