You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

27 lines
599 B

package service
import (
"context"
"testing"
"go-common/app/admin/main/esports/model"
. "github.com/smartystreets/goconvey/convey"
)
func TestService_AddMatch(t *testing.T) {
Convey("test add match", t, WithService(func(s *Service) {
gids := []int64{1}
err := s.AddMatch(context.Background(), &model.Match{Title: "match"}, gids)
So(err, ShouldBeNil)
}))
}
func TestService_ForbidMatch(t *testing.T) {
Convey("test forbid match", t, WithService(func(s *Service) {
mid := int64(1)
state := 0
err := s.ForbidMatch(context.Background(), mid, state)
So(err, ShouldBeNil)
}))
}