mysql_test.go 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. package pendant
  2. import (
  3. "context"
  4. "testing"
  5. . "github.com/smartystreets/goconvey/convey"
  6. )
  7. func TestDaoUpEquipMID(t *testing.T) {
  8. Convey("should return err be nil", t, func() {
  9. res, err := d.UpEquipMID(context.Background(), 11)
  10. So(err, ShouldBeNil)
  11. So(res, ShouldNotBeNil)
  12. })
  13. }
  14. func TestDaoUpEquipExpires(t *testing.T) {
  15. Convey("should return err be nil", t, func() {
  16. res, err := d.UpEquipExpires(context.TODO(), 11, 123121)
  17. So(err, ShouldBeNil)
  18. So(res, ShouldNotBeNil)
  19. })
  20. }
  21. func TestDaoPendantEquipMID(t *testing.T) {
  22. Convey("should return err be nil", t, func() {
  23. res, err := d.PendantEquipMID(context.TODO(), 11)
  24. So(err, ShouldBeNil)
  25. So(res, ShouldNotBeNil)
  26. })
  27. }
  28. func TestDaoExpireEquipPendant(t *testing.T) {
  29. Convey("should return err be nil", t, func() {
  30. res, err := d.ExpireEquipPendant(context.TODO(), 11)
  31. So(err, ShouldBeNil)
  32. So(res, ShouldNotBeNil)
  33. })
  34. }
  35. func TestDaoPendantEquipGidPid(t *testing.T) {
  36. Convey("should return err be nil", t, func() {
  37. res, err := d.PendantEquipGidPid(context.TODO(), 11)
  38. So(err, ShouldBeNil)
  39. So(res, ShouldNotBeNil)
  40. })
  41. }