fix(接口定义): 修复添加后置脚本不触发通知的缺陷
--bug=1026591 --user=王孝刚 【接口测试】接口自动化-场景内接口有一个前置脚本-添加一个后置脚本-未发送通知 https://www.tapd.cn/55049933/s/1377090
This commit is contained in:
parent
f484aa3d43
commit
8f464917ce
|
@ -1151,14 +1151,18 @@ public class ElementUtil {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isSend(List<String> org, List<String> target) {
|
public static boolean isSend(List<String> org, List<String> target) {
|
||||||
if (org.size() != target.size() && CollectionUtils.isEmpty(org)) {
|
if (org.size() != target.size()) {
|
||||||
|
if (CollectionUtils.isEmpty(org)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
if (org.size() != target.size() && CollectionUtils.isEmpty(target)) {
|
if (CollectionUtils.isEmpty(target)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
List<String> diff = org.stream()
|
return true;
|
||||||
.filter(s -> !target.contains(s))
|
|
||||||
|
}
|
||||||
|
List<String> diff = target.stream()
|
||||||
|
.filter(s -> !org.contains(s))
|
||||||
.collect(Collectors.toList());
|
.collect(Collectors.toList());
|
||||||
if (CollectionUtils.isNotEmpty(diff)) {
|
if (CollectionUtils.isNotEmpty(diff)) {
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -1125,13 +1125,16 @@ public class BaseEnvironmentService extends NodeTreeService<ApiModuleDTO> {
|
||||||
|
|
||||||
public static boolean isSend(List<String> orgList, List<String> targetList) {
|
public static boolean isSend(List<String> orgList, List<String> targetList) {
|
||||||
if (orgList.size() != targetList.size() && CollectionUtils.isEmpty(orgList)) {
|
if (orgList.size() != targetList.size() && CollectionUtils.isEmpty(orgList)) {
|
||||||
|
if (CollectionUtils.isEmpty(orgList)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
if (orgList.size() != targetList.size() && CollectionUtils.isEmpty(targetList)) {
|
if (CollectionUtils.isEmpty(targetList)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
List<String> diff = orgList.stream()
|
return true;
|
||||||
.filter(s -> !targetList.contains(s))
|
}
|
||||||
|
List<String> diff = targetList.stream()
|
||||||
|
.filter(s -> !orgList.contains(s))
|
||||||
.collect(Collectors.toList());
|
.collect(Collectors.toList());
|
||||||
if (CollectionUtils.isNotEmpty(diff)) {
|
if (CollectionUtils.isNotEmpty(diff)) {
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Reference in New Issue