recruit_test.go 513 B

123456789101112131415161718192021222324252627
  1. package web
  2. import (
  3. "context"
  4. "net/url"
  5. "testing"
  6. "go-common/app/interface/main/web-goblin/model/web"
  7. . "github.com/smartystreets/goconvey/convey"
  8. )
  9. func TestService_Recruit(t *testing.T) {
  10. Convey("test recruit", t, WithService(func(s *Service) {
  11. var (
  12. ctx = context.Background()
  13. param = url.Values{}
  14. ru = &web.Params{
  15. Route: "v1/jobs",
  16. }
  17. )
  18. param.Set("mode", "social")
  19. res, err := s.Recruit(ctx, param, ru)
  20. So(len(res), ShouldBeGreaterThan)
  21. So(err, ShouldBeNil)
  22. }))
  23. }