1package bug
 2
 3import (
 4	"testing"
 5
 6	"github.com/MichaelMure/git-bug/entities/identity"
 7	"github.com/MichaelMure/git-bug/entity"
 8	"github.com/MichaelMure/git-bug/entity/dag"
 9	"github.com/MichaelMure/git-bug/repository"
10)
11
12func TestAddCommentSerialize(t *testing.T) {
13	dag.SerializeRoundTripTest(t, operationUnmarshaler, func(author identity.Interface, unixTime int64) (*AddCommentOperation, entity.Resolvers) {
14		return NewAddCommentOp(author, unixTime, "message", nil), nil
15	})
16	dag.SerializeRoundTripTest(t, operationUnmarshaler, func(author identity.Interface, unixTime int64) (*AddCommentOperation, entity.Resolvers) {
17		return NewAddCommentOp(author, unixTime, "message", []repository.Hash{"hash1", "hash2"}), nil
18	})
19}