BUILD 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. package(default_visibility = ["//visibility:public"])
  2. load(
  3. "@io_bazel_rules_go//go:def.bzl",
  4. "go_library",
  5. "go_test",
  6. )
  7. go_library(
  8. name = "go_default_library",
  9. srcs = [
  10. "dao.go",
  11. "mc.cache.go",
  12. "mysql.go",
  13. ],
  14. importpath = "go-common/app/job/main/card/dao",
  15. tags = ["automanaged"],
  16. visibility = ["//visibility:public"],
  17. deps = [
  18. "//app/job/main/card/conf:go_default_library",
  19. "//library/cache/memcache:go_default_library",
  20. "//library/database/sql:go_default_library",
  21. "//library/log:go_default_library",
  22. "//library/stat/prom:go_default_library",
  23. "//vendor/github.com/pkg/errors:go_default_library",
  24. ],
  25. )
  26. filegroup(
  27. name = "package-srcs",
  28. srcs = glob(["**"]),
  29. tags = ["automanaged"],
  30. visibility = ["//visibility:private"],
  31. )
  32. filegroup(
  33. name = "all-srcs",
  34. srcs = [":package-srcs"],
  35. tags = ["automanaged"],
  36. visibility = ["//visibility:public"],
  37. )
  38. go_test(
  39. name = "go_default_test",
  40. srcs = [
  41. "dao_test.go",
  42. "mc.cache_test.go",
  43. "mysql_test.go",
  44. ],
  45. embed = [":go_default_library"],
  46. rundir = ".",
  47. tags = ["automanaged"],
  48. deps = [
  49. "//app/job/main/card/conf:go_default_library",
  50. "//vendor/github.com/smartystreets/goconvey/convey:go_default_library",
  51. ],
  52. )