audit_test.go 515 B

123456789101112131415161718192021222324
  1. package dao
  2. import (
  3. "context"
  4. "testing"
  5. "github.com/smartystreets/goconvey/convey"
  6. )
  7. func TestDaoAuditInfo(t *testing.T) {
  8. convey.Convey("AuditInfo", t, func(ctx convey.C) {
  9. var (
  10. c = context.Background()
  11. mid = int64(1)
  12. remoteIP = ""
  13. )
  14. ctx.Convey("When everything goes positive", func(ctx convey.C) {
  15. _, err := d.AuditInfo(c, mid, remoteIP)
  16. ctx.Convey("Then err should be nil.rs should not be nil.", func(ctx convey.C) {
  17. ctx.So(err, convey.ShouldBeNil)
  18. })
  19. })
  20. })
  21. }