Commit 8c7f7a17 authored by 黎博's avatar 黎博

优化

parent 2635f7b7
......@@ -113,7 +113,7 @@ public class AutoUtilsServiceImpl implements AutoUtilsService {
String comparator = map.get("comparator");
String checkpoint = JsonPath.read(response, map.get("check")).toString();
String expectValue = map.get("expect");
boolean result = singleAssertResponse(response, comparator, checkpoint, expectValue);
boolean result = singleAssertResponse(comparator, checkpoint, expectValue);
if (!result) {
return false;
}
......@@ -123,13 +123,12 @@ public class AutoUtilsServiceImpl implements AutoUtilsService {
/**
*
* @param response
* @param comparator
* @param checkpoint
* @param expectValue
* @return
*/
public boolean singleAssertResponse(String response, String comparator, String checkpoint, String expectValue) {
public boolean singleAssertResponse(String comparator, String checkpoint, String expectValue) {
switch (comparator) {
case "eq":
return checkpoint.equals(expectValue);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment