From 1a6c704724e8d439048a6b941ac948ca12d73ea5 Mon Sep 17 00:00:00 2001 From: Shiina Kin Date: Mon, 14 Oct 2024 09:39:22 +0800 Subject: [PATCH] test(UserServiceTest): import missing group config classes to fix compilation errors fix(UserServiceTest): correct image total size in DTO to reflect bytes rather than kilobytes --- .../kotlin/io/sakurasou/service/user/UserServiceTest.kt | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/app/src/test/kotlin/io/sakurasou/service/user/UserServiceTest.kt b/app/src/test/kotlin/io/sakurasou/service/user/UserServiceTest.kt index e24b0926..9194d716 100644 --- a/app/src/test/kotlin/io/sakurasou/service/user/UserServiceTest.kt +++ b/app/src/test/kotlin/io/sakurasou/service/user/UserServiceTest.kt @@ -24,6 +24,8 @@ import io.sakurasou.model.dto.UserSelfUpdateDTO import io.sakurasou.model.entity.Album import io.sakurasou.model.entity.Group import io.sakurasou.model.entity.User +import io.sakurasou.model.group.GroupConfig +import io.sakurasou.model.group.GroupStrategyConfig import io.sakurasou.model.setting.SystemSetting import io.sakurasou.service.setting.SettingService import kotlinx.coroutines.runBlocking @@ -521,9 +523,10 @@ class UserServiceTest { id = 2, name = "UserGroup", description = null, - strategyId = 1 + strategyId = 1, + config = GroupConfig(GroupStrategyConfig()) ) - val imageCountAndTotalSizeDTO = ImageCountAndTotalSizeDTO(10, 2048.0) + val imageCountAndTotalSizeDTO = ImageCountAndTotalSizeDTO(10, 204800) val exceptedUserVO = UserVO( id = userId,