task_weight_config_test.go 869 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. package archive
  2. import (
  3. "context"
  4. "testing"
  5. "go-common/app/admin/main/videoup/model/archive"
  6. . "github.com/smartystreets/goconvey/convey"
  7. )
  8. func Test_GetMaxWeight(t *testing.T) {
  9. Convey("GetMaxWeight", t, WithDao(func(d *Dao) {
  10. _, err := d.GetMaxWeight(context.Background())
  11. So(err, ShouldBeNil)
  12. }))
  13. }
  14. func Test_DelWeightConf(t *testing.T) {
  15. Convey("DelWeightConf", t, WithDao(func(d *Dao) {
  16. _, err := d.DelWeightConf(context.Background(), 0)
  17. So(err, ShouldBeNil)
  18. }))
  19. }
  20. func Test_ListWeightConf(t *testing.T) {
  21. Convey("ListWeightConf", t, WithDao(func(d *Dao) {
  22. _, err := d.ListWeightConf(context.Background(), &archive.Confs{})
  23. So(err, ShouldBeNil)
  24. }))
  25. }
  26. func Test_LWConfigHelp(t *testing.T) {
  27. Convey("LWConfigHelp", t, WithDao(func(d *Dao) {
  28. _, err := d.LWConfigHelp(context.Background(), []int64{1, 2})
  29. So(err, ShouldBeNil)
  30. }))
  31. }