diff --git a/src/test/groovy/org/prebid/server/functional/tests/BaseSpec.groovy b/src/test/groovy/org/prebid/server/functional/tests/BaseSpec.groovy index df2c416722b..63ba2516ff4 100644 --- a/src/test/groovy/org/prebid/server/functional/tests/BaseSpec.groovy +++ b/src/test/groovy/org/prebid/server/functional/tests/BaseSpec.groovy @@ -17,7 +17,6 @@ import org.prebid.server.functional.testcontainers.scaffolding.PrebidCache import org.prebid.server.functional.testcontainers.scaffolding.VendorList import org.prebid.server.functional.util.ObjectMapperWrapper import org.prebid.server.functional.util.PBSUtils -import spock.lang.Shared import spock.lang.Specification import static java.math.RoundingMode.DOWN @@ -44,7 +43,6 @@ abstract class BaseSpec extends Specification implements ObjectMapperWrapper { protected static final Map GENERIC_ALIAS_CONFIG = ["adapters.generic.aliases.alias.enabled" : "true", "adapters.generic.aliases.alias.endpoint": "$networkServiceContainer.rootUri/auction".toString()] - @Shared protected static final PrebidServerService defaultPbsService = pbsServiceFactory.getService([:]) def setupSpec() { diff --git a/src/test/groovy/org/prebid/server/functional/tests/module/AbTestingModuleSpec.groovy b/src/test/groovy/org/prebid/server/functional/tests/module/AbTestingModuleSpec.groovy index b009794cb63..73e4536a9d4 100644 --- a/src/test/groovy/org/prebid/server/functional/tests/module/AbTestingModuleSpec.groovy +++ b/src/test/groovy/org/prebid/server/functional/tests/module/AbTestingModuleSpec.groovy @@ -14,7 +14,6 @@ import org.prebid.server.functional.model.response.auction.AnalyticResult import org.prebid.server.functional.model.response.auction.InvocationResult import org.prebid.server.functional.service.PrebidServerService import org.prebid.server.functional.util.PBSUtils -import spock.lang.Shared import static org.prebid.server.functional.model.ModuleName.PB_RESPONSE_CORRECTION import static org.prebid.server.functional.model.config.Endpoint.OPENRTB2_AUCTION @@ -49,9 +48,7 @@ class AbTestingModuleSpec extends ModuleBaseSpec { private final static Map MULTI_MODULE_CONFIG = getResponseCorrectionConfig() + getOrtb2BlockingSettings() + ['hooks.host-execution-plan': null] - @Shared private static PrebidServerService ortbModulePbsService - @Shared private static PrebidServerService pbsServiceWithMultipleModules def setupSpec() { diff --git a/src/test/groovy/org/prebid/server/functional/tests/module/GeneralModuleSpec.groovy b/src/test/groovy/org/prebid/server/functional/tests/module/GeneralModuleSpec.groovy index 231394afa6a..93ffcc49f82 100644 --- a/src/test/groovy/org/prebid/server/functional/tests/module/GeneralModuleSpec.groovy +++ b/src/test/groovy/org/prebid/server/functional/tests/module/GeneralModuleSpec.groovy @@ -15,7 +15,6 @@ import org.prebid.server.functional.model.request.auction.TraceLevel import org.prebid.server.functional.model.response.auction.InvocationResult import org.prebid.server.functional.service.PrebidServerService import org.prebid.server.functional.util.PBSUtils -import spock.lang.Shared import static org.prebid.server.functional.model.ModuleName.ORTB2_BLOCKING import static org.prebid.server.functional.model.ModuleName.PB_RICHMEDIA_FILTER @@ -46,9 +45,7 @@ class GeneralModuleSpec extends ModuleBaseSpec { getOrtb2BlockingSettings() + ['hooks.host-execution-plan': encode(ExecutionPlan.getSingleEndpointExecutionPlan(OPENRTB2_AUCTION, MODULES_STAGES))] - @Shared private static PrebidServerService pbsServiceWithMultipleModule - @Shared private static PrebidServerService pbsServiceWithMultipleModuleWithRequireInvoke def setupSpec() { diff --git a/src/test/groovy/org/prebid/server/functional/tests/module/analyticstag/AnalyticsTagsModuleSpec.groovy b/src/test/groovy/org/prebid/server/functional/tests/module/analyticstag/AnalyticsTagsModuleSpec.groovy index c625c926303..30e384ffc6d 100644 --- a/src/test/groovy/org/prebid/server/functional/tests/module/analyticstag/AnalyticsTagsModuleSpec.groovy +++ b/src/test/groovy/org/prebid/server/functional/tests/module/analyticstag/AnalyticsTagsModuleSpec.groovy @@ -18,7 +18,6 @@ import org.prebid.server.functional.model.response.auction.ModuleActivityName import org.prebid.server.functional.service.PrebidServerService import org.prebid.server.functional.tests.module.ModuleBaseSpec import org.prebid.server.functional.util.PBSUtils -import spock.lang.Shared import static org.prebid.server.functional.model.ModuleName.ORTB2_BLOCKING import static org.prebid.server.functional.model.ModuleName.PB_RICHMEDIA_FILTER @@ -31,7 +30,6 @@ import static org.prebid.server.functional.model.response.auction.ErrorType.PREB class AnalyticsTagsModuleSpec extends ModuleBaseSpec { - @Shared private static PrebidServerService pbsServiceWithEnabledOrtb2Blocking def setupSpec() { diff --git a/src/test/groovy/org/prebid/server/functional/tests/module/ortb2blocking/Ortb2BlockingSpec.groovy b/src/test/groovy/org/prebid/server/functional/tests/module/ortb2blocking/Ortb2BlockingSpec.groovy index ebe29ea01cc..473cdc5fbce 100644 --- a/src/test/groovy/org/prebid/server/functional/tests/module/ortb2blocking/Ortb2BlockingSpec.groovy +++ b/src/test/groovy/org/prebid/server/functional/tests/module/ortb2blocking/Ortb2BlockingSpec.groovy @@ -33,7 +33,6 @@ import org.prebid.server.functional.model.response.auction.SeatBid import org.prebid.server.functional.service.PrebidServerService import org.prebid.server.functional.tests.module.ModuleBaseSpec import org.prebid.server.functional.util.PBSUtils -import spock.lang.Shared import static org.prebid.server.functional.model.ModuleName.ORTB2_BLOCKING import static org.prebid.server.functional.model.bidder.BidderName.ALIAS @@ -63,7 +62,6 @@ class Ortb2BlockingSpec extends ModuleBaseSpec { private static final Map PBS_CONFIG = getOrtb2BlockingSettings() + IX_CONFIG + ['adapter-defaults.ortb.multiformat-supported': 'false'] - @Shared private static PrebidServerService pbsServiceWithEnabledOrtb2Blocking def setupSpec() { diff --git a/src/test/groovy/org/prebid/server/functional/tests/module/pbrequestcorrection/PbRequestCorrectionSpec.groovy b/src/test/groovy/org/prebid/server/functional/tests/module/pbrequestcorrection/PbRequestCorrectionSpec.groovy index c478032d3d4..3ab3ca92408 100644 --- a/src/test/groovy/org/prebid/server/functional/tests/module/pbrequestcorrection/PbRequestCorrectionSpec.groovy +++ b/src/test/groovy/org/prebid/server/functional/tests/module/pbrequestcorrection/PbRequestCorrectionSpec.groovy @@ -14,7 +14,6 @@ import org.prebid.server.functional.model.request.auction.OperationState import org.prebid.server.functional.service.PrebidServerService import org.prebid.server.functional.tests.module.ModuleBaseSpec import org.prebid.server.functional.util.PBSUtils -import spock.lang.Shared import static org.prebid.server.functional.model.request.auction.DistributionChannel.APP import static org.prebid.server.functional.model.request.auction.OperationState.YES @@ -28,7 +27,6 @@ class PbRequestCorrectionSpec extends ModuleBaseSpec { private static final String ANDROID = "android" private static final String IOS = "IOS" - @Shared private static PrebidServerService pbsServiceWithRequestCorrectionModule def setupSpec() { diff --git a/src/test/groovy/org/prebid/server/functional/tests/module/responsecorrenction/ResponseCorrectionSpec.groovy b/src/test/groovy/org/prebid/server/functional/tests/module/responsecorrenction/ResponseCorrectionSpec.groovy index 0cae9da6844..38b4fd0f810 100644 --- a/src/test/groovy/org/prebid/server/functional/tests/module/responsecorrenction/ResponseCorrectionSpec.groovy +++ b/src/test/groovy/org/prebid/server/functional/tests/module/responsecorrenction/ResponseCorrectionSpec.groovy @@ -16,7 +16,6 @@ import org.prebid.server.functional.model.response.auction.Prebid import org.prebid.server.functional.service.PrebidServerService import org.prebid.server.functional.tests.module.ModuleBaseSpec import org.prebid.server.functional.util.PBSUtils -import spock.lang.Shared import java.time.Instant @@ -38,7 +37,6 @@ class ResponseCorrectionSpec extends ModuleBaseSpec { "adapters.generic.modifying-vast-xml-allowed": "false"] + getResponseCorrectionConfig() - @Shared private static PrebidServerService pbsServiceWithResponseCorrectionModule def setupSpec() { @@ -49,7 +47,6 @@ class ResponseCorrectionSpec extends ModuleBaseSpec { pbsServiceFactory.removeContainer(PBS_CONFIG) } - def "PBS shouldn't modify response when in account correction module disabled"() { given: "Start up time" def start = Instant.now() diff --git a/src/test/groovy/org/prebid/server/functional/tests/privacy/PrivacyBaseSpec.groovy b/src/test/groovy/org/prebid/server/functional/tests/privacy/PrivacyBaseSpec.groovy index 3f249b37fe5..ed633ec5316 100644 --- a/src/test/groovy/org/prebid/server/functional/tests/privacy/PrivacyBaseSpec.groovy +++ b/src/test/groovy/org/prebid/server/functional/tests/privacy/PrivacyBaseSpec.groovy @@ -34,7 +34,6 @@ import org.prebid.server.functional.util.privacy.ConsentString import org.prebid.server.functional.util.privacy.TcfConsent import org.prebid.server.functional.util.privacy.gpp.GppConsent import org.prebid.server.functional.util.privacy.gpp.UsNatV1Consent -import spock.lang.Shared import static org.prebid.server.functional.model.bidder.BidderName.GENERIC import static org.prebid.server.functional.model.bidder.BidderName.OPENX @@ -78,13 +77,9 @@ abstract class PrivacyBaseSpec extends BaseSpec { "gdpr.host-vendor-id" : GENERIC_VENDOR_ID as String, "adapters.generic.ccpa-enforced" : "true"] - @Shared protected static final int PURPOSES_ONLY_GVL_VERSION = PBSUtils.getRandomNumber(0, 4095) - @Shared protected static final int LEG_INT_PURPOSES_ONLY_GVL_VERSION = PBSUtils.getRandomNumberWithExclusion(PURPOSES_ONLY_GVL_VERSION, 0, 4095) - @Shared protected static final int LEG_INT_AND_FLEXIBLE_PURPOSES_GVL_VERSION = PBSUtils.getRandomNumberWithExclusion([PURPOSES_ONLY_GVL_VERSION, LEG_INT_PURPOSES_ONLY_GVL_VERSION], 0, 4095) - @Shared protected static final int PURPOSES_AND_LEG_INT_PURPOSES_GVL_VERSION = PBSUtils.getRandomNumberWithExclusion([PURPOSES_ONLY_GVL_VERSION, LEG_INT_PURPOSES_ONLY_GVL_VERSION, LEG_INT_AND_FLEXIBLE_PURPOSES_GVL_VERSION], 0, 4095) protected static final int EXPONENTIAL_BACKOFF_MAX_DELAY = 1 @@ -109,10 +104,7 @@ abstract class PrivacyBaseSpec extends BaseSpec { protected static final Map GENERAL_PRIVACY_CONFIG = GENERIC_CONFIG + GDPR_VENDOR_LIST_CONFIG + GENERIC_VENDOR_CONFIG + RETRY_POLICY_EXPONENTIAL_CONFIG - @Shared protected static PrebidServerService privacyPbsService - - @Shared protected static PrebidServerService activityPbsService def setupSpec() {