feat: update

This commit is contained in:
Rogee
2025-05-23 23:42:27 +08:00
parent 409a2e8304
commit 1166a5c949
17 changed files with 751 additions and 514 deletions

View File

@@ -52,7 +52,7 @@ func (s *MediasTestSuite) Test_countByCondition() {
Convey("no cond", func() {
database.Truncate(context.Background(), db, table.Medias.TableName())
cnt, err := MediasModel().countByCondition(context.Background(), nil)
cnt, err := MediasModel().Count(context.Background())
Convey("should not return an error", func() {
So(err, ShouldBeNil)
})
@@ -137,7 +137,7 @@ func (s *MediasTestSuite) Test_Create() {
So(err, ShouldBeNil)
})
cnt, err := MediasModel().countByCondition(context.Background(), nil)
cnt, err := MediasModel().Count(context.Background())
Convey("Count should not return an error", func() {
So(err, ShouldBeNil)
})
@@ -169,7 +169,7 @@ func (s *MediasTestSuite) Test_Page() {
So(err, ShouldBeNil)
}
cnt, err := MediasModel().countByCondition(context.Background(), nil)
cnt, err := MediasModel().Count(context.Background())
So(err, ShouldBeNil)
So(cnt, ShouldEqual, 20)
})