From d146fb26d6e36e4ed5b2b4468da856b1f058fb2c Mon Sep 17 00:00:00 2001 From: ColdClear <3124364150@qq.com> Date: Thu, 28 Sep 2023 18:43:42 +0800 Subject: [PATCH] remove useless code --- .../handler/UninstallBizHandlerTests.java | 22 +++++++++++++++++-- .../arklet/core/util/AssertUtilsTests.java | 16 ++++++++++++++ 2 files changed, 36 insertions(+), 2 deletions(-) diff --git a/sofa-serverless-runtime/arklet-core/src/test/java/com/alipay/sofa/serverless/arklet/core/command/handler/UninstallBizHandlerTests.java b/sofa-serverless-runtime/arklet-core/src/test/java/com/alipay/sofa/serverless/arklet/core/command/handler/UninstallBizHandlerTests.java index cbb7782d3..b2c164d7d 100644 --- a/sofa-serverless-runtime/arklet-core/src/test/java/com/alipay/sofa/serverless/arklet/core/command/handler/UninstallBizHandlerTests.java +++ b/sofa-serverless-runtime/arklet-core/src/test/java/com/alipay/sofa/serverless/arklet/core/command/handler/UninstallBizHandlerTests.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package com.alipay.sofa.serverless.arklet.core.command.handler; import com.alipay.sofa.ark.api.ClientResponse; @@ -27,7 +43,8 @@ public void testHandle_Success() throws Throwable { input.setBizName("testBizName"); input.setBizVersion("testBizVersion"); - when(handler.getOperationService().uninstall(input.getBizName(), input.getBizVersion())).thenReturn(success); + when(handler.getOperationService().uninstall(input.getBizName(), input.getBizVersion())) + .thenReturn(success); Output result = handler.handle(input); @@ -41,7 +58,8 @@ public void testHandle_Failure() throws Throwable { input.setBizName("testBizName"); input.setBizVersion("testBizVersion"); - when(handler.getOperationService().uninstall(input.getBizName(), input.getBizVersion())).thenReturn(failed); + when(handler.getOperationService().uninstall(input.getBizName(), input.getBizVersion())) + .thenReturn(failed); Output result = handler.handle(input); diff --git a/sofa-serverless-runtime/arklet-core/src/test/java/com/alipay/sofa/serverless/arklet/core/util/AssertUtilsTests.java b/sofa-serverless-runtime/arklet-core/src/test/java/com/alipay/sofa/serverless/arklet/core/util/AssertUtilsTests.java index a3a609087..73f01ada7 100644 --- a/sofa-serverless-runtime/arklet-core/src/test/java/com/alipay/sofa/serverless/arklet/core/util/AssertUtilsTests.java +++ b/sofa-serverless-runtime/arklet-core/src/test/java/com/alipay/sofa/serverless/arklet/core/util/AssertUtilsTests.java @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package com.alipay.sofa.serverless.arklet.core.util; import org.junit.Assert;