mask_test.go 767 B

12345678910111213141516171819202122232425262728293031323334
  1. package dao
  2. import (
  3. "context"
  4. "testing"
  5. "github.com/smartystreets/goconvey/convey"
  6. )
  7. func TestDaomaskURI(t *testing.T) {
  8. convey.Convey("maskURI", t, func(ctx convey.C) {
  9. ctx.Convey("When everything goes positive", func(ctx convey.C) {
  10. p1 := testDao.maskURI()
  11. ctx.Convey("Then p1 should not be nil.", func(ctx convey.C) {
  12. ctx.So(p1, convey.ShouldNotBeNil)
  13. })
  14. })
  15. })
  16. }
  17. func TestDaoGenerateMask(t *testing.T) {
  18. convey.Convey("GenerateMask", t, func(ctx convey.C) {
  19. var (
  20. c = context.Background()
  21. cid = int64(0)
  22. mid = int64(0)
  23. plat = int8(0)
  24. priority = int32(0)
  25. )
  26. ctx.Convey("When everything goes positive", func(ctx convey.C) {
  27. testDao.GenerateMask(c, cid, mid, plat, priority, 0, 0, 0)
  28. })
  29. })
  30. }