mirror of
https://github.com/ccmjga/zhilu-admin
synced 2026-03-14 13:43:42 +08:00
init ai backend
This commit is contained in:
@@ -15,7 +15,6 @@ import com.zl.mjga.repository.PermissionRepository;
|
||||
import com.zl.mjga.repository.RoleRepository;
|
||||
import com.zl.mjga.repository.UserRepository;
|
||||
import com.zl.mjga.service.IdentityAccessService;
|
||||
import java.time.OffsetDateTime;
|
||||
import java.util.List;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -58,21 +57,22 @@ public class JacksonAnnotationMvcTest {
|
||||
.andExpect(jsonPath("$.data[0].password").doesNotExist());
|
||||
}
|
||||
|
||||
// @Test
|
||||
// @WithMockUser
|
||||
// void dateFieldWithFormatAnnotation_whenResponseIncludeField_fieldShouldBeExpectDataFormat()
|
||||
// throws Exception {
|
||||
// OffsetDateTime stubCreateDateTime =
|
||||
// OffsetDateTime.of(2023, 12, 2, 1, 1, 1, 0, OffsetDateTime.now().getOffset());
|
||||
// UserRolePermissionDto stubUserRolePermissionDto = new UserRolePermissionDto();
|
||||
// stubUserRolePermissionDto.setCreateTime(stubCreateDateTime);
|
||||
// when(identityAccessService.pageQueryUser(any(PageRequestDto.class), any(UserQueryDto.class)))
|
||||
// .thenReturn(new PageResponseDto<>(1, List.of(stubUserRolePermissionDto)));
|
||||
// mockMvc
|
||||
// .perform(
|
||||
// get(String.format("/iam/users?page=1&size=5&username=%s", "7bF3mcNVTj6P6v2"))
|
||||
// .contentType(MediaType.APPLICATION_FORM_URLENCODED))
|
||||
// .andExpect(status().isOk())
|
||||
// .andExpect(jsonPath("$.data[0].createTime").value("2023-12-02 01:01:01"));
|
||||
// }
|
||||
// @Test
|
||||
// @WithMockUser
|
||||
// void dateFieldWithFormatAnnotation_whenResponseIncludeField_fieldShouldBeExpectDataFormat()
|
||||
// throws Exception {
|
||||
// OffsetDateTime stubCreateDateTime =
|
||||
// OffsetDateTime.of(2023, 12, 2, 1, 1, 1, 0, OffsetDateTime.now().getOffset());
|
||||
// UserRolePermissionDto stubUserRolePermissionDto = new UserRolePermissionDto();
|
||||
// stubUserRolePermissionDto.setCreateTime(stubCreateDateTime);
|
||||
// when(identityAccessService.pageQueryUser(any(PageRequestDto.class),
|
||||
// any(UserQueryDto.class)))
|
||||
// .thenReturn(new PageResponseDto<>(1, List.of(stubUserRolePermissionDto)));
|
||||
// mockMvc
|
||||
// .perform(
|
||||
// get(String.format("/iam/users?page=1&size=5&username=%s", "7bF3mcNVTj6P6v2"))
|
||||
// .contentType(MediaType.APPLICATION_FORM_URLENCODED))
|
||||
// .andExpect(status().isOk())
|
||||
// .andExpect(jsonPath("$.data[0].createTime").value("2023-12-02 01:01:01"));
|
||||
// }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user