✅ 补充司机改号不回写单据快照的守卫测试
This commit is contained in:
+11
@@ -105,6 +105,17 @@ class DriverSyncMobileTest {
|
||||
verify(driverMapper, never()).updateById(any(Driver.class));
|
||||
}
|
||||
|
||||
@Test
|
||||
@DisplayName("改号链路不持有运单/配载服务:换号只改档案,不回写单据上的手机号快照")
|
||||
void phoneSyncDoesNotDependOnWaybillServices() {
|
||||
for (Field field : DriverServiceImpl.class.getDeclaredFields()) {
|
||||
String typeName = field.getType().getSimpleName();
|
||||
assertFalse(typeName.contains("Waybill") || typeName.contains("LoadingManage"),
|
||||
"改号链路引入了 " + typeName + ":换号不得顺手回写运单/配载单的司机快照,"
|
||||
+ "否则司机档案与历史单据的归属会一起漂移");
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
@DisplayName("档案 mobile 与账号旧号不一致:不动档案,返回可读原因(不抛异常)")
|
||||
void skipsWhenProfileMobileDiffersFromOldPhone() {
|
||||
|
||||
Reference in New Issue
Block a user