fix: 修复自动生成的随机字符串包含特殊字符导致action不能正常结束

This commit is contained in:
CaptainB 2024-02-19 16:48:38 +08:00 committed by 刘瑞斌
parent b35fdf8355
commit 9d109c3d7e
3 changed files with 4 additions and 4 deletions

View File

@ -1,7 +1,7 @@
package io.metersphere.system.base.param;
import jakarta.validation.constraints.Max;
import org.testcontainers.shaded.org.apache.commons.lang3.RandomStringUtils;
import org.apache.commons.lang3.RandomStringUtils;
import java.lang.annotation.Annotation;
import java.lang.reflect.Field;

View File

@ -1,7 +1,7 @@
package io.metersphere.system.base.param;
import jakarta.validation.constraints.Min;
import org.testcontainers.shaded.org.apache.commons.lang3.RandomStringUtils;
import org.apache.commons.lang3.RandomStringUtils;
import java.lang.annotation.Annotation;
import java.lang.reflect.Field;

View File

@ -1,7 +1,7 @@
package io.metersphere.system.base.param;
import jakarta.validation.constraints.Size;
import org.testcontainers.shaded.org.apache.commons.lang3.RandomStringUtils;
import org.apache.commons.lang3.RandomStringUtils;
import java.lang.annotation.Annotation;
import java.lang.reflect.Field;
@ -22,7 +22,7 @@ public class SizeParamGenerator extends ParamGenerator {
return max + 1;
} else {
// todo 做缓存优化
return RandomStringUtils.random(max + 1);
return RandomStringUtils.randomAlphanumeric(max + 1);
}
}
}