diff --git a/src/test/java/com/dispose/controller/TaskControllerQATest.java b/src/test/java/com/dispose/controller/TaskControllerQATest.java index f44ab448..ed235a02 100644 --- a/src/test/java/com/dispose/controller/TaskControllerQATest.java +++ b/src/test/java/com/dispose/controller/TaskControllerQATest.java @@ -666,11 +666,9 @@ public class TaskControllerQATest extends InitTestEnvironment { Assert.assertNotNull(task.getMessage()); if (task.getStatus() == 0) { - Assert.assertEquals(String.valueOf(task.getStatus()), "0"); - Assert.assertEquals(task.getMessage(), "成功"); + Assert.assertEquals(Long.valueOf(task.getStatus()), Long.valueOf(ErrorCode.ERR_OK.getCode())); } else { - Assert.assertNotEquals(String.valueOf(task.getStatus()), "0"); - Assert.assertNotEquals(task.getMessage(), "成功"); + Assert.assertNotEquals(Long.valueOf(task.getStatus()), Long.valueOf(ErrorCode.ERR_OK.getCode())); } if (task.getType() != null) { @@ -718,11 +716,9 @@ public class TaskControllerQATest extends InitTestEnvironment { Assert.assertNotNull(task.getMessage()); if (task.getStatus() == 0) { - Assert.assertEquals(String.valueOf(task.getStatus()), "0"); - Assert.assertEquals(task.getMessage(), "成功"); + Assert.assertEquals(Long.valueOf(task.getStatus()), Long.valueOf(ErrorCode.ERR_OK.getCode())); } else { - Assert.assertNotEquals(String.valueOf(task.getStatus()), "0"); - Assert.assertNotEquals(task.getMessage(), "成功"); + Assert.assertNotEquals(Long.valueOf(task.getStatus()), Long.valueOf(ErrorCode.ERR_OK.getCode())); } if (task.getType() != null) { @@ -881,11 +877,9 @@ public class TaskControllerQATest extends InitTestEnvironment { Assert.assertNotNull(task.getMessage()); if (task.getStatus() == 0) { - Assert.assertEquals(String.valueOf(task.getStatus()), "0"); - Assert.assertEquals(task.getMessage(), "成功"); + Assert.assertEquals(Long.valueOf(task.getStatus()), Long.valueOf(ErrorCode.ERR_OK.getCode())); } else { - Assert.assertNotEquals(String.valueOf(task.getStatus()), "0"); - Assert.assertNotEquals(task.getMessage(), "成功"); + Assert.assertNotEquals(Long.valueOf(task.getStatus()), Long.valueOf(ErrorCode.ERR_OK.getCode())); } if (task.getType() != null) { @@ -932,11 +926,9 @@ public class TaskControllerQATest extends InitTestEnvironment { Assert.assertNotNull(task.getMessage()); if (task.getStatus() == 0) { - Assert.assertEquals(String.valueOf(task.getStatus()), "0"); - Assert.assertEquals(task.getMessage(), "成功"); + Assert.assertEquals(Long.valueOf(task.getStatus()), Long.valueOf(ErrorCode.ERR_OK.getCode())); } else { - Assert.assertNotEquals(String.valueOf(task.getStatus()), "0"); - Assert.assertNotEquals(task.getMessage(), "成功"); + Assert.assertNotEquals(Long.valueOf(task.getStatus()), Long.valueOf(ErrorCode.ERR_OK.getCode())); } if (task.getType() != null) { @@ -984,11 +976,9 @@ public class TaskControllerQATest extends InitTestEnvironment { Assert.assertNotNull(task.getMessage()); if (task.getStatus() == 0) { - Assert.assertEquals(String.valueOf(task.getStatus()), "0"); - Assert.assertEquals(task.getMessage(), "成功"); + Assert.assertEquals(Long.valueOf(task.getStatus()), Long.valueOf(ErrorCode.ERR_OK.getCode())); } else { - Assert.assertNotEquals(String.valueOf(task.getStatus()), "0"); - Assert.assertNotEquals(task.getMessage(), "成功"); + Assert.assertNotEquals(Long.valueOf(task.getStatus()), Long.valueOf(ErrorCode.ERR_OK.getCode())); } if (task.getType() != null) {