From df8be05e23aed518d43ebf3729e933649e3d0dc8 Mon Sep 17 00:00:00 2001 From: Anil Gupta Date: Tue, 12 Sep 2023 12:02:11 +0530 Subject: [PATCH] Issue #LR-627 merge: From release-5.3.1 to 5.4.0 (#1224) --- .gitignore | 2 +- Jenkinsfile | 4 +-- controller/pom.xml | 2 +- .../OrganisationControllerTest.java | 24 +++++++++--------- core/es-utils/pom.xml | 2 +- .../dependency-reduced-pom.xml | 2 +- core/notification-utils/pom.xml | 2 +- core/platform-common/pom.xml | 2 +- pom.xml | 2 +- .../organisation/OrgManagementActorTest.java | 25 ++++++++++--------- 10 files changed, 34 insertions(+), 33 deletions(-) diff --git a/.gitignore b/.gitignore index 7e99a28fe9..a66e8a21f2 100644 --- a/.gitignore +++ b/.gitignore @@ -18,4 +18,4 @@ RUNNING_PID /.target/ /bin/ /logs -.vscode +.vscode/** diff --git a/Jenkinsfile b/Jenkinsfile index b09b4fc5e3..08f7c76929 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -29,9 +29,9 @@ node('build-slave') { sh "mvn clean install -DskipTests=true -DCLOUD_STORE_GROUP_ID=${params.cloud_store_group_id} -DCLOUD_STORE_ARTIFACT_ID=${params.cloud_store_artifact_id} -DCLOUD_STORE_VERSION=${params.cloud_store_version}" } - /* stage('Unit Tests') { + stage('Unit Tests') { sh "mvn clean install '-Dtest=!%regex[io.opensaber.registry.client.*]' -DfailIfNoTests=false -Dsurefire.failIfNoSpecifiedTests=false -DCLOUD_STORE_GROUP_ID=org.sunbird -DCLOUD_STORE_ARTIFACT_ID=cloud-store-sdk -DCLOUD_STORE_VERSION=1.4.6" - } */ + } stage('Package') { dir('controller') { sh 'mvn play2:dist' diff --git a/controller/pom.xml b/controller/pom.xml index c77c31ef05..15542e2cad 100644 --- a/controller/pom.xml +++ b/controller/pom.xml @@ -212,7 +212,7 @@ junit junit - 4.12 + 4.13.1 test diff --git a/controller/test/controllers/organisationmanagement/OrganisationControllerTest.java b/controller/test/controllers/organisationmanagement/OrganisationControllerTest.java index 65f83c379d..18525c98c2 100644 --- a/controller/test/controllers/organisationmanagement/OrganisationControllerTest.java +++ b/controller/test/controllers/organisationmanagement/OrganisationControllerTest.java @@ -1,23 +1,11 @@ package controllers.organisationmanagement; -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertTrue; -import static org.powermock.api.mockito.PowerMockito.when; - import akka.stream.javadsl.FileIO; import akka.stream.javadsl.Source; import akka.util.ByteString; import com.fasterxml.jackson.databind.JsonNode; import controllers.BaseApplicationTest; import controllers.DummyActor; -import java.io.File; -import java.io.IOException; -import java.nio.file.Files; -import java.nio.file.Paths; -import java.util.Arrays; -import java.util.Collections; -import java.util.HashMap; -import java.util.Map; import modules.OnRequestHandler; import org.junit.Before; import org.junit.Test; @@ -33,6 +21,18 @@ import util.ACTORS; import util.RequestInterceptor; +import java.io.File; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Paths; +import java.util.Arrays; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; + +import static org.junit.Assert.assertEquals; +import static org.powermock.api.mockito.PowerMockito.when; + @PrepareForTest(OnRequestHandler.class) @PowerMockIgnore({"javax.management.*", "jdk.internal.reflect.*", "javax.crypto.*"}) // @Ignore diff --git a/core/es-utils/pom.xml b/core/es-utils/pom.xml index f975e40a9d..d501570052 100644 --- a/core/es-utils/pom.xml +++ b/core/es-utils/pom.xml @@ -34,7 +34,7 @@ junit junit - 4.12 + 4.13.1 test diff --git a/core/notification-utils/dependency-reduced-pom.xml b/core/notification-utils/dependency-reduced-pom.xml index ec20fac3d2..be370caaaa 100644 --- a/core/notification-utils/dependency-reduced-pom.xml +++ b/core/notification-utils/dependency-reduced-pom.xml @@ -40,7 +40,7 @@ junit junit - 4.12 + 4.13.1 test diff --git a/core/notification-utils/pom.xml b/core/notification-utils/pom.xml index eb7c8e20af..daeacaac14 100644 --- a/core/notification-utils/pom.xml +++ b/core/notification-utils/pom.xml @@ -29,7 +29,7 @@ junit junit - 4.12 + 4.13.1 test diff --git a/core/platform-common/pom.xml b/core/platform-common/pom.xml index f5fc22c670..d6cd701690 100644 --- a/core/platform-common/pom.xml +++ b/core/platform-common/pom.xml @@ -87,7 +87,7 @@ junit junit - 4.12 + 4.13.1 test diff --git a/pom.xml b/pom.xml index 468696a606..2be0a632ab 100644 --- a/pom.xml +++ b/pom.xml @@ -23,7 +23,7 @@ junit junit - 4.12 + 4.13.1 test diff --git a/service/src/test/java/org/sunbird/actor/organisation/OrgManagementActorTest.java b/service/src/test/java/org/sunbird/actor/organisation/OrgManagementActorTest.java index 2b198a6a9a..652986e860 100644 --- a/service/src/test/java/org/sunbird/actor/organisation/OrgManagementActorTest.java +++ b/service/src/test/java/org/sunbird/actor/organisation/OrgManagementActorTest.java @@ -1,23 +1,11 @@ package org.sunbird.actor.organisation; -import static akka.testkit.JavaTestKit.duration; -import static org.junit.Assert.assertTrue; -import static org.powermock.api.mockito.PowerMockito.*; - import akka.actor.ActorRef; import akka.actor.ActorSelection; import akka.actor.ActorSystem; import akka.actor.Props; import akka.dispatch.Futures; import akka.testkit.javadsl.TestKit; -import java.io.File; -import java.nio.file.Files; -import java.nio.file.Path; -import java.nio.file.Paths; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; import org.junit.Assert; import org.junit.Before; import org.junit.Ignore; @@ -56,6 +44,19 @@ import scala.Option; import scala.concurrent.Promise; +import java.io.File; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import static akka.testkit.JavaTestKit.duration; +import static org.junit.Assert.assertTrue; +import static org.powermock.api.mockito.PowerMockito.*; + @RunWith(PowerMockRunner.class) @PrepareForTest({ ServiceFactory.class,