From 534645ae19df7ecaf327ce4a81e76b96a2942168 Mon Sep 17 00:00:00 2001 From: Amalka Subasinghe Date: Thu, 6 Jul 2023 17:15:53 +0530 Subject: [PATCH] fixed unit tests --- .../io.entgra.device.mgt.plugins.mobile.android.api/pom.xml | 6 +----- .../android/api/DeviceManagementAdminServiceTests.java | 3 ++- pom.xml | 4 ++-- 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/components/mobile-plugins/android-plugin/io.entgra.device.mgt.plugins.mobile.android.api/pom.xml b/components/mobile-plugins/android-plugin/io.entgra.device.mgt.plugins.mobile.android.api/pom.xml index bd4f742a4..0309c0c3a 100644 --- a/components/mobile-plugins/android-plugin/io.entgra.device.mgt.plugins.mobile.android.api/pom.xml +++ b/components/mobile-plugins/android-plugin/io.entgra.device.mgt.plugins.mobile.android.api/pom.xml @@ -306,7 +306,7 @@ org.powermock - powermock-api-mockito + powermock-api-mockito2 test @@ -349,8 +349,4 @@ jackson-core-asl - - - true - diff --git a/components/mobile-plugins/android-plugin/io.entgra.device.mgt.plugins.mobile.android.api/src/test/java/io/entgra/device/mgt/plugins/mobile/android/api/DeviceManagementAdminServiceTests.java b/components/mobile-plugins/android-plugin/io.entgra.device.mgt.plugins.mobile.android.api/src/test/java/io/entgra/device/mgt/plugins/mobile/android/api/DeviceManagementAdminServiceTests.java index 1b5bc301e..f38864b0e 100644 --- a/components/mobile-plugins/android-plugin/io.entgra.device.mgt.plugins.mobile.android.api/src/test/java/io/entgra/device/mgt/plugins/mobile/android/api/DeviceManagementAdminServiceTests.java +++ b/components/mobile-plugins/android-plugin/io.entgra.device.mgt.plugins.mobile.android.api/src/test/java/io/entgra/device/mgt/plugins/mobile/android/api/DeviceManagementAdminServiceTests.java @@ -25,6 +25,7 @@ import org.powermock.api.mockito.PowerMockito; import org.powermock.core.classloader.annotations.PowerMockIgnore; import org.powermock.core.classloader.annotations.PrepareForTest; import org.powermock.modules.testng.PowerMockObjectFactory; +import org.powermock.modules.testng.PowerMockTestCase; import org.testng.Assert; import org.testng.IObjectFactory; import org.testng.annotations.BeforeClass; @@ -40,7 +41,7 @@ import javax.ws.rs.core.Response; @PowerMockIgnore({"javax.ws.rs.*", "org.apache.log4j.*"}) @PrepareForTest(AndroidAPIUtils.class) -public class DeviceManagementAdminServiceTests { +public class DeviceManagementAdminServiceTests extends PowerMockTestCase { private DeviceManagementAdminServiceImpl deviceManagementAdminService; diff --git a/pom.xml b/pom.xml index 07c849c78..12400ba15 100644 --- a/pom.xml +++ b/pom.xml @@ -865,7 +865,7 @@ org.powermock - powermock-api-mockito + powermock-api-mockito2 ${powermock.version} test @@ -1071,7 +1071,7 @@ 1.0b3 1.4.0.wso2v1 3.12.1.GA - 1.7.4 + 2.0.2 4.6.0 1.13.0