prebid.js 7.43.0 → 7.45.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/33acrossBidAdapter.js +1 -1
- package/dist/33acrossIdSystem.js +1 -1
- package/dist/acuityAdsBidAdapter.js +1 -1
- package/dist/adagioBidAdapter.js +1 -1
- package/dist/adbookpspBidAdapter.js +1 -1
- package/dist/adgenerationBidAdapter.js +1 -1
- package/dist/adkernelAdnAnalyticsAdapter.js +1 -1
- package/dist/admixerIdSystem.js +1 -1
- package/dist/adnuntiusBidAdapter.js +1 -1
- package/dist/adqueryBidAdapter.js +1 -1
- package/dist/adqueryIdSystem.js +1 -1
- package/dist/adrelevantisBidAdapter.js +1 -1
- package/dist/adrinoBidAdapter.js +1 -1
- package/dist/adriverIdSystem.js +1 -1
- package/dist/adsinteractiveBidAdapter.js +1 -0
- package/dist/adtrgtmeBidAdapter.js +1 -1
- package/dist/adxcgBidAdapter.js +1 -1
- package/dist/adyoulikeBidAdapter.js +1 -1
- package/dist/aidemBidAdapter.js +1 -1
- package/dist/airgridRtdProvider.js +1 -1
- package/dist/ajaBidAdapter.js +1 -1
- package/dist/akamaiDapRtdProvider.js +1 -1
- package/dist/amxBidAdapter.js +1 -1
- package/dist/amxIdSystem.js +1 -1
- package/dist/appierAnalyticsAdapter.js +1 -1
- package/dist/appnexusBidAdapter.js +1 -1
- package/dist/appushBidAdapter.js +1 -1
- package/dist/apstreamBidAdapter.js +1 -1
- package/dist/asoBidAdapter.js +1 -1
- package/dist/atsAnalyticsAdapter.js +1 -1
- package/dist/audiencerunBidAdapter.js +1 -1
- package/dist/axonixBidAdapter.js +1 -1
- package/dist/bedigitechBidAdapter.js +1 -0
- package/dist/beyondmediaBidAdapter.js +1 -1
- package/dist/bidglassBidAdapter.js +1 -1
- package/dist/big-richmediaBidAdapter.js +1 -1
- package/dist/bluebillywigBidAdapter.js +1 -1
- package/dist/blueconicRtdProvider.js +1 -1
- package/dist/braveBidAdapter.js +1 -1
- package/dist/bridgewellBidAdapter.js +1 -1
- package/dist/brightMountainMediaBidAdapter.js +1 -1
- package/dist/brightcomBidAdapter.js +1 -1
- package/dist/brightcomSSPBidAdapter.js +1 -1
- package/dist/browsiRtdProvider.js +1 -1
- package/dist/byDataAnalyticsAdapter.js +1 -1
- package/dist/carodaBidAdapter.js +1 -1
- package/dist/chtnwBidAdapter.js +1 -1
- package/dist/coinzillaBidAdapter.js +1 -1
- package/dist/compassBidAdapter.js +1 -1
- package/dist/concertBidAdapter.js +1 -1
- package/dist/connectIdSystem.js +1 -1
- package/dist/connectadBidAdapter.js +1 -1
- package/dist/consumableBidAdapter.js +1 -1
- package/dist/contentexchangeBidAdapter.js +1 -1
- package/dist/conversantAnalyticsAdapter.js +1 -1
- package/dist/conversantBidAdapter.js +1 -1
- package/dist/craftBidAdapter.js +1 -1
- package/dist/criteoBidAdapter.js +1 -1
- package/dist/criteoIdSystem.js +1 -1
- package/dist/cwireBidAdapter.js +1 -1
- package/dist/czechAdIdSystem.js +1 -1
- package/dist/dacIdSystem.js +1 -1
- package/dist/deepintentDpesIdSystem.js +1 -1
- package/dist/dependencies.json +15 -0
- package/dist/discoveryBidAdapter.js +1 -1
- package/dist/domainOverrideToRootDomain.js +1 -0
- package/dist/dspxBidAdapter.js +1 -1
- package/dist/eplanningBidAdapter.js +1 -1
- package/dist/feedadBidAdapter.js +1 -1
- package/dist/finativeBidAdapter.js +1 -1
- package/dist/fintezaAnalyticsAdapter.js +1 -1
- package/dist/fledgeForGpt.js +1 -1
- package/dist/freewheel-sspBidAdapter.js +1 -1
- package/dist/ftrackIdSystem.js +1 -1
- package/dist/gdprEnforcement.js +1 -1
- package/dist/glimpseBidAdapter.js +1 -1
- package/dist/globalsunBidAdapter.js +1 -1
- package/dist/gmosspBidAdapter.js +1 -1
- package/dist/gnetBidAdapter.js +1 -1
- package/dist/goldbachBidAdapter.js +1 -1
- package/dist/gravitoIdSystem.js +1 -1
- package/dist/greenbidsAnalyticsAdapter.js +1 -0
- package/dist/gridBidAdapter.js +1 -1
- package/dist/gridNMBidAdapter.js +1 -1
- package/dist/growthCodeAnalyticsAdapter.js +1 -1
- package/dist/growthCodeIdSystem.js +1 -1
- package/dist/gumgumBidAdapter.js +1 -1
- package/dist/h12mediaBidAdapter.js +1 -1
- package/dist/hadronAnalyticsAdapter.js +1 -1
- package/dist/hadronIdSystem.js +1 -1
- package/dist/hadronRtdProvider.js +1 -1
- package/dist/id5IdSystem.js +1 -1
- package/dist/idWardRtdProvider.js +1 -1
- package/dist/identityLinkIdSystem.js +1 -1
- package/dist/idxIdSystem.js +1 -1
- package/dist/imRtdProvider.js +1 -1
- package/dist/impactifyBidAdapter.js +1 -1
- package/dist/improvedigitalBidAdapter.js +1 -1
- package/dist/imuIdSystem.js +1 -1
- package/dist/inmarBidAdapter.js +1 -1
- package/dist/insticatorBidAdapter.js +1 -1
- package/dist/intentIqIdSystem.js +1 -1
- package/dist/invibesBidAdapter.js +1 -1
- package/dist/iqzoneBidAdapter.js +1 -1
- package/dist/ivsBidAdapter.js +1 -0
- package/dist/ixBidAdapter.js +1 -1
- package/dist/jixieBidAdapter.js +1 -1
- package/dist/justpremiumBidAdapter.js +1 -1
- package/dist/jwplayerVideoProvider.js +1 -1
- package/dist/kargoBidAdapter.js +1 -1
- package/dist/koblerBidAdapter.js +1 -1
- package/dist/konduitAnalyticsAdapter.js +1 -1
- package/dist/kueezBidAdapter.js +1 -1
- package/dist/kueezRtbBidAdapter.js +1 -1
- package/dist/kulturemediaBidAdapter.js +1 -1
- package/dist/lassoBidAdapter.js +1 -1
- package/dist/lifestreetBidAdapter.js +1 -1
- package/dist/liveIntentIdSystem.js +1 -1
- package/dist/liveyieldAnalyticsAdapter.js +1 -1
- package/dist/logicadBidAdapter.js +1 -1
- package/dist/loglyliftBidAdapter.js +1 -1
- package/dist/lotamePanoramaIdSystem.js +1 -1
- package/dist/luponmediaBidAdapter.js +1 -1
- package/dist/magniteAnalyticsAdapter.js +1 -1
- package/dist/malltvAnalyticsAdapter.js +1 -1
- package/dist/marsmediaBidAdapter.js +1 -1
- package/dist/mathildeadsBidAdapter.js +1 -1
- package/dist/mediafuseBidAdapter.js +1 -1
- package/dist/mediagoBidAdapter.js +1 -1
- package/dist/mediakeysBidAdapter.js +1 -1
- package/dist/medianetBidAdapter.js +1 -1
- package/dist/mediasquareBidAdapter.js +1 -1
- package/dist/merkleIdSystem.js +1 -1
- package/dist/mgidBidAdapter.js +1 -1
- package/dist/mgidRtdProvider.js +1 -1
- package/dist/minutemediaBidAdapter.js +1 -1
- package/dist/minutemediaplusBidAdapter.js +1 -1
- package/dist/mwOpenLinkIdSystem.js +1 -1
- package/dist/naveggIdSystem.js +1 -1
- package/dist/nexx360BidAdapter.js +1 -1
- package/dist/nobidBidAdapter.js +1 -1
- package/dist/not-for-prod/prebid.js +232 -227
- package/dist/novatiqIdSystem.js +1 -1
- package/dist/oguryBidAdapter.js +1 -1
- package/dist/onetagBidAdapter.js +1 -1
- package/dist/onomagicBidAdapter.js +1 -1
- package/dist/ooloAnalyticsAdapter.js +1 -1
- package/dist/openxBidAdapter.js +1 -1
- package/dist/openxOrtbBidAdapter.js +1 -1
- package/dist/operaadsBidAdapter.js +1 -1
- package/dist/optidigitalBidAdapter.js +1 -1
- package/dist/ortbConverter.js +1 -1
- package/dist/outbrainBidAdapter.js +1 -1
- package/dist/parrableIdSystem.js +1 -1
- package/dist/permutiveRtdProvider.js +1 -1
- package/dist/pixfutureBidAdapter.js +1 -1
- package/dist/prebid-core.js +1 -1
- package/dist/prebidServerBidAdapter.js +1 -1
- package/dist/prebidmanagerAnalyticsAdapter.js +1 -1
- package/dist/pubCommonId.js +1 -1
- package/dist/publinkIdSystem.js +1 -1
- package/dist/pubmaticAnalyticsAdapter.js +1 -1
- package/dist/pubmaticBidAdapter.js +1 -1
- package/dist/pubwiseAnalyticsAdapter.js +1 -1
- package/dist/pubxBidAdapter.js +1 -1
- package/dist/pxyzBidAdapter.js +1 -1
- package/dist/quantcastBidAdapter.js +1 -1
- package/dist/quantcastIdSystem.js +1 -1
- package/dist/readpeakBidAdapter.js +1 -1
- package/dist/realvuAnalyticsAdapter.js +1 -1
- package/dist/relaidoBidAdapter.js +1 -1
- package/dist/rhythmoneBidAdapter.js +1 -1
- package/dist/riseBidAdapter.js +1 -1
- package/dist/roxotAnalyticsAdapter.js +1 -1
- package/dist/rtbhouseBidAdapter.js +1 -1
- package/dist/rtdModule.js +1 -1
- package/dist/rubiconAnalyticsAdapter.js +1 -1
- package/dist/rubiconBidAdapter.js +1 -1
- package/dist/seedingAllianceBidAdapter.js +1 -1
- package/dist/seedtagBidAdapter.js +1 -1
- package/dist/sharedIdSystem.js +1 -1
- package/dist/sharethroughAnalyticsAdapter.js +1 -1
- package/dist/sharethroughBidAdapter.js +1 -1
- package/dist/shinezBidAdapter.js +1 -1
- package/dist/sigmoidAnalyticsAdapter.js +1 -1
- package/dist/smaatoBidAdapter.js +1 -1
- package/dist/smartadserverBidAdapter.js +1 -1
- package/dist/smarthubBidAdapter.js +1 -1
- package/dist/smartxBidAdapter.js +1 -1
- package/dist/smilewantedBidAdapter.js +1 -1
- package/dist/sonobiBidAdapter.js +1 -1
- package/dist/sovrnAnalyticsAdapter.js +1 -1
- package/dist/sovrnBidAdapter.js +1 -1
- package/dist/sspBCBidAdapter.js +1 -1
- package/dist/staqAnalyticsAdapter.js +1 -1
- package/dist/stroeerCoreBidAdapter.js +1 -1
- package/dist/stvBidAdapter.js +1 -1
- package/dist/sublimeBidAdapter.js +1 -1
- package/dist/synacormediaBidAdapter.js +1 -1
- package/dist/taboolaBidAdapter.js +1 -1
- package/dist/targetVideoBidAdapter.js +1 -1
- package/dist/teadsBidAdapter.js +1 -1
- package/dist/teadsIdSystem.js +1 -1
- package/dist/trionBidAdapter.js +1 -1
- package/dist/tripleliftBidAdapter.js +1 -1
- package/dist/truereachBidAdapter.js +1 -1
- package/dist/trustpidSystem.js +1 -1
- package/dist/ttdBidAdapter.js +1 -1
- package/dist/ucfunnelAnalyticsAdapter.js +1 -1
- package/dist/uid2IdSystem.js +1 -1
- package/dist/underdogmediaBidAdapter.js +1 -1
- package/dist/undertoneBidAdapter.js +1 -1
- package/dist/userId.js +1 -1
- package/dist/validationFpdModule.js +1 -1
- package/dist/vidazooBidAdapter.js +1 -1
- package/dist/videobyteBidAdapter.js +1 -1
- package/dist/videoheroesBidAdapter.js +1 -1
- package/dist/vidoomyBidAdapter.js +1 -1
- package/dist/visiblemeasuresBidAdapter.js +1 -1
- package/dist/visxBidAdapter.js +1 -1
- package/dist/vrtcalBidAdapter.js +1 -1
- package/dist/vuukleBidAdapter.js +1 -1
- package/dist/weboramaRtdProvider.js +1 -1
- package/dist/widespaceBidAdapter.js +1 -1
- package/dist/winrBidAdapter.js +1 -1
- package/dist/yahoosspBidAdapter.js +1 -1
- package/dist/yieldmoBidAdapter.js +1 -1
- package/dist/yieldoneAnalyticsAdapter.js +1 -1
- package/dist/yieldoneBidAdapter.js +1 -1
- package/dist/yuktamediaAnalyticsAdapter.js +1 -1
- package/dist/zeotapIdPlusIdSystem.js +1 -1
- package/dist/zeta_global_sspBidAdapter.js +1 -1
- package/libraries/domainOverrideToRootDomain/index.js +39 -0
- package/libraries/ortbConverter/converter.js +3 -2
- package/modules/33acrossIdSystem.js +5 -2
- package/modules/acuityAdsBidAdapter.js +1 -1
- package/modules/adagioBidAdapter.js +3 -4
- package/modules/adkernelAdnAnalyticsAdapter.js +4 -2
- package/modules/admixerIdSystem.js +4 -2
- package/modules/adnuntiusBidAdapter.js +1 -1
- package/modules/adqueryBidAdapter.js +1 -1
- package/modules/adqueryIdSystem.js +2 -1
- package/modules/adrinoBidAdapter.js +24 -16
- package/modules/adriverIdSystem.js +3 -2
- package/modules/adsinteractiveBidAdapter.js +144 -0
- package/modules/adsinteractiveBidAdapter.md +31 -0
- package/modules/adyoulikeBidAdapter.js +2 -3
- package/modules/aidemBidAdapter.js +5 -0
- package/modules/airgridRtdProvider.js +4 -2
- package/modules/ajaBidAdapter.js +38 -16
- package/modules/akamaiDapRtdProvider.js +2 -1
- package/modules/amxBidAdapter.js +12 -10
- package/modules/amxIdSystem.js +23 -20
- package/modules/amxIdSystem.md +7 -7
- package/modules/appnexusBidAdapter.js +8 -8
- package/modules/appushBidAdapter.js +1 -1
- package/modules/apstreamBidAdapter.js +1 -1
- package/modules/atsAnalyticsAdapter.js +4 -2
- package/modules/audiencerunBidAdapter.js +9 -10
- package/modules/bedigitechBidAdapter.js +67 -0
- package/modules/bedigitechBidAdapter.md +32 -0
- package/modules/beyondmediaBidAdapter.js +1 -1
- package/modules/bluebillywigBidAdapter.js +2 -4
- package/modules/blueconicRtdProvider.js +2 -1
- package/modules/braveBidAdapter.js +1 -1
- package/modules/brightcomBidAdapter.js +1 -2
- package/modules/brightcomSSPBidAdapter.js +1 -2
- package/modules/browsiRtdProvider.js +4 -2
- package/modules/byDataAnalyticsAdapter.js +6 -3
- package/modules/coinzillaBidAdapter.js +1 -2
- package/modules/compassBidAdapter.js +1 -1
- package/modules/concertBidAdapter.js +14 -7
- package/modules/connectIdSystem.js +96 -21
- package/modules/connectIdSystem.md +6 -5
- package/modules/connectadBidAdapter.js +2 -4
- package/modules/contentexchangeBidAdapter.js +1 -1
- package/modules/craftBidAdapter.js +29 -24
- package/modules/criteoBidAdapter.js +4 -2
- package/modules/criteoIdSystem.js +6 -2
- package/modules/czechAdIdSystem.js +3 -2
- package/modules/dacIdSystem.js +4 -3
- package/modules/deepintentDpesIdSystem.js +3 -2
- package/modules/discoveryBidAdapter.js +1 -1
- package/modules/dspxBidAdapter.js +223 -15
- package/modules/fintezaAnalyticsAdapter.js +5 -3
- package/modules/fledgeForGpt.js +54 -6
- package/modules/freewheel-sspBidAdapter.js +8 -0
- package/modules/ftrackIdSystem.js +6 -6
- package/modules/gdprEnforcement.js +56 -68
- package/modules/glimpseBidAdapter.js +2 -6
- package/modules/globalsunBidAdapter.js +1 -1
- package/modules/gnetBidAdapter.js +1 -2
- package/modules/gravitoIdSystem.js +5 -3
- package/modules/greenbidsAnalyticsAdapter.js +181 -0
- package/modules/greenbidsAnalyticsAdapter.md +23 -0
- package/modules/gridBidAdapter.js +14 -8
- package/modules/gridNMBidAdapter.js +1 -1
- package/modules/growthCodeAnalyticsAdapter.js +3 -2
- package/modules/growthCodeIdSystem.js +21 -17
- package/modules/gumgumBidAdapter.js +8 -18
- package/modules/hadronAnalyticsAdapter.js +5 -3
- package/modules/hadronIdSystem.js +3 -1
- package/modules/hadronRtdProvider.js +4 -2
- package/modules/id5IdSystem.js +4 -2
- package/modules/idWardRtdProvider.js +2 -1
- package/modules/identityLinkIdSystem.js +5 -2
- package/modules/idxIdSystem.js +3 -2
- package/modules/imRtdProvider.js +3 -1
- package/modules/impactifyBidAdapter.js +2 -4
- package/modules/imuIdSystem.js +6 -3
- package/modules/insticatorBidAdapter.js +1 -1
- package/modules/intentIqIdSystem.js +3 -2
- package/modules/invibesBidAdapter.js +1 -1
- package/modules/iqzoneBidAdapter.js +1 -1
- package/modules/ivsBidAdapter.js +85 -0
- package/modules/ivsBidAdapter.md +34 -0
- package/modules/ixBidAdapter.js +43 -106
- package/modules/jixieBidAdapter.js +3 -6
- package/modules/jwplayerVideoProvider.js +25 -32
- package/modules/kargoBidAdapter.js +1 -1
- package/modules/koblerBidAdapter.js +1 -2
- package/modules/kueezBidAdapter.js +1 -1
- package/modules/kueezRtbBidAdapter.js +1 -1
- package/modules/liveIntentIdSystem.js +11 -2
- package/modules/lotamePanoramaIdSystem.js +3 -2
- package/modules/luponmediaBidAdapter.js +1 -1
- package/modules/magniteAnalyticsAdapter.js +101 -9
- package/modules/mathildeadsBidAdapter.js +1 -1
- package/modules/mediafuseBidAdapter.js +1 -1
- package/modules/mediagoBidAdapter.js +1 -1
- package/modules/mediakeysBidAdapter.js +2 -3
- package/modules/medianetBidAdapter.js +1 -1
- package/modules/merkleIdSystem.js +2 -1
- package/modules/mgidBidAdapter.js +179 -27
- package/modules/mgidRtdProvider.js +3 -1
- package/modules/minutemediaBidAdapter.js +1 -1
- package/modules/minutemediaplusBidAdapter.js +1 -1
- package/modules/mwOpenLinkIdSystem.js +3 -2
- package/modules/naveggIdSystem.js +3 -2
- package/modules/nexx360BidAdapter.js +0 -1
- package/modules/nobidBidAdapter.js +1 -1
- package/modules/novatiqIdSystem.js +6 -3
- package/modules/oguryBidAdapter.js +3 -2
- package/modules/onetagBidAdapter.js +1 -1
- package/modules/onomagicBidAdapter.js +1 -2
- package/modules/openxBidAdapter.js +192 -563
- package/modules/openxBidAdapter.md +22 -20
- package/modules/openxOrtbBidAdapter.js +24 -10
- package/modules/openxOrtbBidAdapter.md +11 -8
- package/modules/operaadsBidAdapter.js +1 -1
- package/modules/parrableIdSystem.js +4 -2
- package/modules/permutiveRtdProvider.js +2 -1
- package/modules/prebidServerBidAdapter/index.js +9 -3
- package/modules/prebidServerBidAdapter/ortbConverter.js +12 -2
- package/modules/prebidmanagerAnalyticsAdapter.js +3 -2
- package/modules/pubCommonId.js +6 -3
- package/modules/publinkIdSystem.js +2 -1
- package/modules/pubmaticAnalyticsAdapter.js +12 -1
- package/modules/pubmaticBidAdapter.js +193 -223
- package/modules/pubwiseAnalyticsAdapter.js +5 -3
- package/modules/pubxBidAdapter.js +5 -2
- package/modules/quantcastBidAdapter.js +1 -1
- package/modules/quantcastIdSystem.js +5 -3
- package/modules/realvuAnalyticsAdapter.js +6 -3
- package/modules/riseBidAdapter.js +1 -1
- package/modules/roxotAnalyticsAdapter.js +5 -2
- package/modules/rtbhouseBidAdapter.js +5 -3
- package/modules/rtdModule/index.js +3 -0
- package/modules/rubiconAnalyticsAdapter.js +3 -2
- package/modules/rubiconBidAdapter.js +1 -0
- package/modules/sharedIdSystem.js +16 -36
- package/modules/sharethroughBidAdapter.js +2 -3
- package/modules/shinezBidAdapter.js +1 -1
- package/modules/sigmoidAnalyticsAdapter.js +4 -2
- package/modules/smartadserverBidAdapter.js +2 -3
- package/modules/smarthubBidAdapter.js +1 -1
- package/modules/sovrnBidAdapter.js +2 -3
- package/modules/staqAnalyticsAdapter.js +5 -3
- package/modules/stroeerCoreBidAdapter.js +3 -2
- package/modules/synacormediaBidAdapter.js +1 -3
- package/modules/taboolaBidAdapter.js +4 -2
- package/modules/teadsBidAdapter.js +1 -1
- package/modules/teadsIdSystem.js +2 -1
- package/modules/tripleliftBidAdapter.js +1 -1
- package/modules/truereachBidAdapter.js +1 -2
- package/modules/trustpidSystem.js +3 -2
- package/modules/ttdBidAdapter.js +11 -5
- package/modules/uid2IdSystem.js +3 -2
- package/modules/undertoneBidAdapter.js +1 -0
- package/modules/userId/eids.js +18 -0
- package/modules/userId/eids.md +16 -0
- package/modules/userId/index.js +5 -2
- package/modules/validationFpdModule/index.js +3 -2
- package/modules/vidazooBidAdapter.js +14 -5
- package/modules/videoheroesBidAdapter.js +1 -1
- package/modules/vidoomyBidAdapter.js +51 -2
- package/modules/visiblemeasuresBidAdapter.js +1 -1
- package/modules/vrtcalBidAdapter.js +1 -1
- package/modules/weboramaRtdProvider.js +3 -1
- package/modules/yieldmoBidAdapter.js +2 -3
- package/modules/yieldoneBidAdapter.js +1 -1
- package/modules/yuktamediaAnalyticsAdapter.js +4 -2
- package/modules/zeotapIdPlusIdSystem.js +3 -2
- package/modules/zeta_global_sspBidAdapter.js +3 -0
- package/package.json +1 -1
- package/plugins/eslint/validateImports.js +13 -14
- package/plugins/pbjsGlobals.js +3 -1
- package/src/Renderer.js +2 -1
- package/src/activities/modules.js +5 -0
- package/src/adapterManager.js +4 -8
- package/src/adapters/bidderFactory.js +30 -16
- package/src/consentHandler.js +42 -0
- package/src/native.js +5 -1
- package/src/refererDetection.js +39 -21
- package/src/secureCreatives.js +2 -2
- package/src/storageManager.js +33 -47
- package/src/userSync.js +7 -4
- package/test/spec/auctionmanager_spec.js +2 -2
- package/test/spec/libraries/domainOverrideToRootDomain/index_spec.js +77 -0
- package/test/spec/modules/33acrossIdSystem_spec.js +1 -1
- package/test/spec/modules/acuityAdsBidAdapter_spec.js +2 -1
- package/test/spec/modules/adagioBidAdapter_spec.js +11 -17
- package/test/spec/modules/admixerIdSystem_spec.js +0 -3
- package/test/spec/modules/adnuntiusBidAdapter_spec.js +6 -6
- package/test/spec/modules/adrinoBidAdapter_spec.js +65 -34
- package/test/spec/modules/adsinteractiveBidAdapter_spec.js +207 -0
- package/test/spec/modules/adyoulikeBidAdapter_spec.js +13 -11
- package/test/spec/modules/aidemBidAdapter_spec.js +72 -8
- package/test/spec/modules/amxBidAdapter_spec.js +4 -1
- package/test/spec/modules/amxIdSystem_spec.js +13 -26
- package/test/spec/modules/appushBidAdapter_spec.js +2 -1
- package/test/spec/modules/atsAnalyticsAdapter_spec.js +2 -2
- package/test/spec/modules/audiencerunBidAdapter_spec.js +8 -11
- package/test/spec/modules/bedigitechBidAdapter_spec.js +145 -0
- package/test/spec/modules/beyondmediaBidAdapter_spec.js +2 -1
- package/test/spec/modules/bluebillywigBidAdapter_spec.js +1 -3
- package/test/spec/modules/compassBidAdapter_spec.js +2 -1
- package/test/spec/modules/concertBidAdapter_spec.js +3 -8
- package/test/spec/modules/connectIdSystem_spec.js +420 -242
- package/test/spec/modules/connectadBidAdapter_spec.js +11 -3
- package/test/spec/modules/contentexchangeBidAdapter_spec.js +2 -1
- package/test/spec/modules/criteoBidAdapter_spec.js +29 -0
- package/test/spec/modules/criteoIdSystem_spec.js +38 -0
- package/test/spec/modules/datablocksBidAdapter_spec.js +0 -1
- package/test/spec/modules/dspxBidAdapter_spec.js +184 -13
- package/test/spec/modules/eids_spec.js +30 -0
- package/test/spec/modules/fledge_spec.js +173 -2
- package/test/spec/modules/freewheel-sspBidAdapter_spec.js +37 -0
- package/test/spec/modules/gdprEnforcement_spec.js +134 -164
- package/test/spec/modules/globalsunBidAdapter_spec.js +2 -1
- package/test/spec/modules/greenbidsAnalyticsAdapter_spec.js +418 -0
- package/test/spec/modules/gridBidAdapter_spec.js +9 -5
- package/test/spec/modules/growthCodeIdSystem_spec.js +2 -1
- package/test/spec/modules/id5IdSystem_spec.js +41 -4
- package/test/spec/modules/identityLinkIdSystem_spec.js +2 -2
- package/test/spec/modules/improvedigitalBidAdapter_spec.js +10 -3
- package/test/spec/modules/iqzoneBidAdapter_spec.js +2 -1
- package/test/spec/modules/ivsBidAdapter_spec.js +197 -0
- package/test/spec/modules/ixBidAdapter_spec.js +84 -71
- package/test/spec/modules/jixieBidAdapter_spec.js +42 -60
- package/test/spec/modules/koblerBidAdapter_spec.js +0 -20
- package/test/spec/modules/liveIntentIdSystem_spec.js +10 -0
- package/test/spec/modules/luponmediaBidAdapter_spec.js +1 -1
- package/test/spec/modules/magniteAnalyticsAdapter_spec.js +129 -1
- package/test/spec/modules/mathildeadsBidAdapter_spec.js +2 -1
- package/test/spec/modules/mediakeysBidAdapter_spec.js +12 -16
- package/test/spec/modules/mgidBidAdapter_spec.js +184 -36
- package/test/spec/modules/oguryBidAdapter_spec.js +19 -4
- package/test/spec/modules/openxBidAdapter_spec.js +1157 -1936
- package/test/spec/modules/openxOrtbBidAdapter_spec.js +108 -50
- package/test/spec/modules/prebidServerBidAdapter_spec.js +68 -2
- package/test/spec/modules/publinkIdSystem_spec.js +3 -2
- package/test/spec/modules/pubmaticBidAdapter_spec.js +67 -10
- package/test/spec/modules/pubxBidAdapter_spec.js +10 -2
- package/test/spec/modules/realTimeDataModule_spec.js +22 -0
- package/test/spec/modules/realvuAnalyticsAdapter_spec.js +0 -1
- package/test/spec/modules/relaidoBidAdapter_spec.js +5 -5
- package/test/spec/modules/rubiconBidAdapter_spec.js +2 -1
- package/test/spec/modules/sharedIdSystem_spec.js +0 -46
- package/test/spec/modules/sharethroughBidAdapter_spec.js +99 -22
- package/test/spec/modules/smartadserverBidAdapter_spec.js +74 -12
- package/test/spec/modules/smarthubBidAdapter_spec.js +2 -1
- package/test/spec/modules/sovrnBidAdapter_spec.js +25 -6
- package/test/spec/modules/stroeerCoreBidAdapter_spec.js +13 -18
- package/test/spec/modules/synacormediaBidAdapter_spec.js +0 -26
- package/test/spec/modules/taboolaBidAdapter_spec.js +101 -0
- package/test/spec/modules/ttdBidAdapter_spec.js +25 -7
- package/test/spec/modules/userId_spec.js +68 -0
- package/test/spec/modules/vidazooBidAdapter_spec.js +13 -0
- package/test/spec/modules/videoModule/submodules/jwplayerVideoProvider_spec.js +17 -4
- package/test/spec/modules/vidoomyBidAdapter_spec.js +68 -0
- package/test/spec/modules/visiblemeasuresBidAdapter_spec.js +2 -1
- package/test/spec/modules/vrtcalBidAdapter_spec.js +3 -2
- package/test/spec/modules/yieldmoBidAdapter_spec.js +18 -2
- package/test/spec/modules/zeotapIdPlusIdSystem_spec.js +3 -2
- package/test/spec/modules/zeta_global_sspBidAdapter_spec.js +8 -0
- package/test/spec/refererDetection_spec.js +56 -1
- package/test/spec/renderer_spec.js +1 -2
- package/test/spec/unit/core/adapterManager_spec.js +21 -58
- package/test/spec/unit/core/bidderFactory_spec.js +28 -10
- package/test/spec/unit/core/consentHandler_spec.js +29 -1
- package/test/spec/unit/core/storageManager_spec.js +31 -21
- package/test/spec/userSync_spec.js +2 -1
|
@@ -19,7 +19,7 @@ import { PLAYBACK_MODE } from 'libraries/video/constants/constants.js';
|
|
|
19
19
|
function getPlayerMock() {
|
|
20
20
|
return makePlayerFactoryMock({
|
|
21
21
|
getState: function () {},
|
|
22
|
-
setup: function () {},
|
|
22
|
+
setup: function () { return this; },
|
|
23
23
|
getViewable: function () {},
|
|
24
24
|
getPercentViewable: function () {},
|
|
25
25
|
getMute: function () {},
|
|
@@ -30,8 +30,8 @@ function getPlayerMock() {
|
|
|
30
30
|
getFullscreen: function () {},
|
|
31
31
|
getPlaylistItem: function () {},
|
|
32
32
|
playAd: function () {},
|
|
33
|
-
on: function () {},
|
|
34
|
-
off: function () {},
|
|
33
|
+
on: function () { return this; },
|
|
34
|
+
off: function () { return this; },
|
|
35
35
|
remove: function () {},
|
|
36
36
|
getAudioTracks: function () {},
|
|
37
37
|
getCurrentAudioTrack: function () {},
|
|
@@ -142,7 +142,7 @@ describe('JWPlayerProvider', function () {
|
|
|
142
142
|
it('should instantiate the player when uninstantiated', function () {
|
|
143
143
|
const player = getPlayerMock();
|
|
144
144
|
config.playerConfig = {};
|
|
145
|
-
const setupSpy = player.setup = sinon.spy();
|
|
145
|
+
const setupSpy = player.setup = sinon.spy(player.setup);
|
|
146
146
|
const provider = JWPlayerProvider(config, makePlayerFactoryMock(player), adState, timeState, callbackStorage, utilsMock, sharedUtils);
|
|
147
147
|
provider.init();
|
|
148
148
|
expect(setupSpy.calledOnce).to.be.true;
|
|
@@ -158,6 +158,19 @@ describe('JWPlayerProvider', function () {
|
|
|
158
158
|
expect(setupComplete.calledOnce).to.be.true;
|
|
159
159
|
});
|
|
160
160
|
|
|
161
|
+
it('should support multiple setup complete event handlers', function () {
|
|
162
|
+
const player = getPlayerMock();
|
|
163
|
+
player.getState = () => 'idle';
|
|
164
|
+
const provider = JWPlayerProvider(config, makePlayerFactoryMock(player), adState, timeState, callbackStorage, utilsMock, sharedUtils);
|
|
165
|
+
const setupComplete = sinon.spy();
|
|
166
|
+
const setupComplete2 = sinon.spy();
|
|
167
|
+
provider.onEvent(SETUP_COMPLETE, setupComplete, {});
|
|
168
|
+
provider.onEvent(SETUP_COMPLETE, setupComplete2, {});
|
|
169
|
+
provider.init();
|
|
170
|
+
expect(setupComplete.calledOnce).to.be.true;
|
|
171
|
+
expect(setupComplete2.calledOnce).to.be.true;
|
|
172
|
+
});
|
|
173
|
+
|
|
161
174
|
it('should not reinstantiate player', function () {
|
|
162
175
|
const player = getPlayerMock();
|
|
163
176
|
player.getState = () => 'idle';
|
|
@@ -74,6 +74,33 @@ describe('vidoomyBidAdapter', function() {
|
|
|
74
74
|
'sizes': [[300, 250], [200, 100]]
|
|
75
75
|
}
|
|
76
76
|
},
|
|
77
|
+
'schain': {
|
|
78
|
+
ver: '1.0',
|
|
79
|
+
complete: 1,
|
|
80
|
+
nodes: [
|
|
81
|
+
{
|
|
82
|
+
'asi': 'exchange1.com',
|
|
83
|
+
'sid': '1234!abcd',
|
|
84
|
+
'hp': 1,
|
|
85
|
+
'rid': 'bid-request-1',
|
|
86
|
+
'name': 'publisher, Inc.',
|
|
87
|
+
'domain': 'publisher.com'
|
|
88
|
+
},
|
|
89
|
+
{
|
|
90
|
+
'asi': 'exchange2.com',
|
|
91
|
+
'sid': 'abcd',
|
|
92
|
+
'hp': 1
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
'asi': 'exchange2.com',
|
|
96
|
+
'sid': 'abcd',
|
|
97
|
+
'hp': 1,
|
|
98
|
+
'rid': 'bid-request-2',
|
|
99
|
+
'name': 'intermediary',
|
|
100
|
+
'domain': 'intermediary.com'
|
|
101
|
+
}
|
|
102
|
+
]
|
|
103
|
+
}
|
|
77
104
|
},
|
|
78
105
|
{
|
|
79
106
|
'bidder': 'vidoomy',
|
|
@@ -128,6 +155,47 @@ describe('vidoomyBidAdapter', function() {
|
|
|
128
155
|
expect('' + request[1].data.id).to.equal('456456');
|
|
129
156
|
expect('' + request[1].data.pid).to.equal('456456');
|
|
130
157
|
});
|
|
158
|
+
|
|
159
|
+
it('should send schain parameter in serialized form', function () {
|
|
160
|
+
const serializedForm = '1.0,1!exchange1.com,1234%21abcd,1,bid-request-1,publisher%2C%20Inc.,publisher.com!exchange2.com,abcd,1,,,!exchange2.com,abcd,1,bid-request-2,intermediary,intermediary.com'
|
|
161
|
+
expect(request[0].data).to.include.any.keys('schain');
|
|
162
|
+
expect(request[0].data.schain).to.eq(serializedForm);
|
|
163
|
+
});
|
|
164
|
+
|
|
165
|
+
it('should set the bidfloor if getFloor module is undefined but static bidfloor is present', function () {
|
|
166
|
+
const request = { ...bidRequests[0], params: { bidfloor: 2.5 } }
|
|
167
|
+
const req = spec.buildRequests([request], bidderRequest)[0];
|
|
168
|
+
expect(req.data).to.include.any.keys('bidfloor');
|
|
169
|
+
expect(req.data.bidfloor).to.equal(2.5);
|
|
170
|
+
});
|
|
171
|
+
|
|
172
|
+
describe('floorModule', function () {
|
|
173
|
+
const getFloordata = {
|
|
174
|
+
'currency': 'USD',
|
|
175
|
+
'floor': 1.60
|
|
176
|
+
};
|
|
177
|
+
bidRequests[0].getFloor = _ => {
|
|
178
|
+
return getFloordata;
|
|
179
|
+
};
|
|
180
|
+
it('should return getFloor.floor if present', function () {
|
|
181
|
+
const request = spec.buildRequests(bidRequests, bidderRequest)[0];
|
|
182
|
+
expect(request.data.bidfloor).to.equal(getFloordata.floor);
|
|
183
|
+
});
|
|
184
|
+
it('should return the getFloor.floor if it is greater than static bidfloor', function () {
|
|
185
|
+
const bidfloor = 1.40;
|
|
186
|
+
const request = { ...bidRequests[0] };
|
|
187
|
+
request.params.bidfloor = bidfloor;
|
|
188
|
+
const bidRequest = spec.buildRequests([request], bidderRequest)[0];
|
|
189
|
+
expect(bidRequest.data.bidfloor).to.equal(getFloordata.floor);
|
|
190
|
+
});
|
|
191
|
+
it('should return the static bidfloor if it is greater than getFloor.floor', function () {
|
|
192
|
+
const bidfloor = 1.90;
|
|
193
|
+
const request = { ...bidRequests[0] };
|
|
194
|
+
request.params.bidfloor = bidfloor;
|
|
195
|
+
const bidRequest = spec.buildRequests([request], bidderRequest)[0];
|
|
196
|
+
expect(bidRequest.data.bidfloor).to.equal(bidfloor);
|
|
197
|
+
});
|
|
198
|
+
});
|
|
131
199
|
});
|
|
132
200
|
|
|
133
201
|
describe('interpretResponse', function () {
|
|
@@ -78,7 +78,8 @@ describe('VisibleMeasuresBidAdapter', function () {
|
|
|
78
78
|
gdprConsent: 'COvFyGBOvFyGBAbAAAENAPCAAOAAAAAAAAAAAEEUACCKAAA.IFoEUQQgAIQwgIwQABAEAAAAOIAACAIAAAAQAIAgEAACEAAAAAgAQBAAAAAAAGBAAgAAAAAAAFAAECAAAgAAQARAEQAAAAAJAAIAAgAAAYQEAAAQmAgBC3ZAYzUw',
|
|
79
79
|
refererInfo: {
|
|
80
80
|
referer: 'https://test.com'
|
|
81
|
-
}
|
|
81
|
+
},
|
|
82
|
+
timeout: 500
|
|
82
83
|
};
|
|
83
84
|
|
|
84
85
|
describe('isBidRequestValid', function () {
|
|
@@ -28,7 +28,8 @@ describe('vrtcalBidAdapter', function () {
|
|
|
28
28
|
'bidId': 'bidID0001',
|
|
29
29
|
'bidderRequestId': 'br0001',
|
|
30
30
|
'auctionId': 'auction0001',
|
|
31
|
-
'userIdAsEids': {}
|
|
31
|
+
'userIdAsEids': {},
|
|
32
|
+
timeout: 435
|
|
32
33
|
}
|
|
33
34
|
];
|
|
34
35
|
|
|
@@ -95,7 +96,7 @@ describe('vrtcalBidAdapter', function () {
|
|
|
95
96
|
w: 300,
|
|
96
97
|
h: 250,
|
|
97
98
|
crid: 'v2_1064_vrt_vrtcaltestdisplay2_300_250',
|
|
98
|
-
adomain: ['vrtcal.com']
|
|
99
|
+
adomain: ['vrtcal.com'],
|
|
99
100
|
}],
|
|
100
101
|
seat: '16'
|
|
101
102
|
}],
|
|
@@ -371,7 +371,15 @@ describe('YieldmoAdapter', function () {
|
|
|
371
371
|
|
|
372
372
|
it('should add eids to the banner bid request', function () {
|
|
373
373
|
const params = {
|
|
374
|
-
|
|
374
|
+
userIdAsEids: [{
|
|
375
|
+
source: 'pubcid.org',
|
|
376
|
+
uids: [
|
|
377
|
+
{
|
|
378
|
+
id: 'fake_pubcid',
|
|
379
|
+
atype: 1,
|
|
380
|
+
}
|
|
381
|
+
]
|
|
382
|
+
}],
|
|
375
383
|
fakeUserIdAsEids: [{
|
|
376
384
|
source: 'pubcid.org',
|
|
377
385
|
uids: [{
|
|
@@ -532,7 +540,15 @@ describe('YieldmoAdapter', function () {
|
|
|
532
540
|
|
|
533
541
|
it('should add eids to the video bid request', function () {
|
|
534
542
|
const params = {
|
|
535
|
-
|
|
543
|
+
userIdAsEids: [{
|
|
544
|
+
source: 'pubcid.org',
|
|
545
|
+
uids: [
|
|
546
|
+
{
|
|
547
|
+
id: 'fake_pubcid',
|
|
548
|
+
atype: 1,
|
|
549
|
+
}
|
|
550
|
+
]
|
|
551
|
+
}],
|
|
536
552
|
fakeUserIdAsEids: [{
|
|
537
553
|
source: 'pubcid.org',
|
|
538
554
|
uids: [{
|
|
@@ -4,6 +4,7 @@ import { config } from 'src/config.js';
|
|
|
4
4
|
import { init, requestBidsHook, setSubmoduleRegistry } from 'modules/userId/index.js';
|
|
5
5
|
import { storage, getStorage, zeotapIdPlusSubmodule } from 'modules/zeotapIdPlusIdSystem.js';
|
|
6
6
|
import * as storageManager from 'src/storageManager.js';
|
|
7
|
+
import {MODULE_TYPE_UID} from '../../../src/activities/modules.js';
|
|
7
8
|
|
|
8
9
|
const ZEOTAP_COOKIE_NAME = 'IDP';
|
|
9
10
|
const ZEOTAP_COOKIE = 'THIS-IS-A-DUMMY-COOKIE';
|
|
@@ -52,9 +53,9 @@ describe('Zeotap ID System', function() {
|
|
|
52
53
|
});
|
|
53
54
|
|
|
54
55
|
it('when a stored Zeotap ID exists it is added to bids', function() {
|
|
55
|
-
|
|
56
|
+
getStorage();
|
|
56
57
|
expect(getStorageManagerSpy.calledOnce).to.be.true;
|
|
57
|
-
sinon.assert.calledWith(getStorageManagerSpy, {
|
|
58
|
+
sinon.assert.calledWith(getStorageManagerSpy, {moduleType: MODULE_TYPE_UID, moduleName: 'zeotapIdPlus'});
|
|
58
59
|
});
|
|
59
60
|
});
|
|
60
61
|
|
|
@@ -51,6 +51,7 @@ describe('Zeta Ssp Bid Adapter', function () {
|
|
|
51
51
|
},
|
|
52
52
|
sid: 'publisherId',
|
|
53
53
|
shortname: 'test_shortname',
|
|
54
|
+
tagid: 'test_tag_id',
|
|
54
55
|
site: {
|
|
55
56
|
page: 'testPage'
|
|
56
57
|
},
|
|
@@ -396,4 +397,11 @@ describe('Zeta Ssp Bid Adapter', function () {
|
|
|
396
397
|
|
|
397
398
|
expect(payload.source.ext.schain).to.eql(schain);
|
|
398
399
|
});
|
|
400
|
+
|
|
401
|
+
it('Test tagid provided', function () {
|
|
402
|
+
const request = spec.buildRequests(bannerRequest, bannerRequest[0]);
|
|
403
|
+
const payload = JSON.parse(request.data);
|
|
404
|
+
|
|
405
|
+
expect(payload.imp[0].tagid).to.eql(params.tagid);
|
|
406
|
+
});
|
|
399
407
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {detectReferer, ensureProtocol, parseDomain} from 'src/refererDetection.js';
|
|
1
|
+
import {cacheWithLocation, detectReferer, ensureProtocol, parseDomain} from 'src/refererDetection.js';
|
|
2
2
|
import {config} from 'src/config.js';
|
|
3
3
|
import {expect} from 'chai';
|
|
4
4
|
|
|
@@ -493,3 +493,58 @@ describe('parseDomain', () => {
|
|
|
493
493
|
})
|
|
494
494
|
})
|
|
495
495
|
});
|
|
496
|
+
|
|
497
|
+
describe('cacheWithLocation', () => {
|
|
498
|
+
let fn, win, cached;
|
|
499
|
+
const RESULT = 'result';
|
|
500
|
+
beforeEach(() => {
|
|
501
|
+
fn = sinon.stub().callsFake(() => RESULT);
|
|
502
|
+
win = {
|
|
503
|
+
location: {
|
|
504
|
+
},
|
|
505
|
+
document: {
|
|
506
|
+
querySelector: sinon.stub()
|
|
507
|
+
}
|
|
508
|
+
}
|
|
509
|
+
});
|
|
510
|
+
|
|
511
|
+
describe('when window is not on top', () => {
|
|
512
|
+
beforeEach(() => {
|
|
513
|
+
win.top = {};
|
|
514
|
+
cached = cacheWithLocation(fn, win);
|
|
515
|
+
})
|
|
516
|
+
|
|
517
|
+
it('should not cache', () => {
|
|
518
|
+
win.top = {};
|
|
519
|
+
cached();
|
|
520
|
+
expect(cached()).to.eql(RESULT);
|
|
521
|
+
expect(fn.callCount).to.eql(2);
|
|
522
|
+
});
|
|
523
|
+
})
|
|
524
|
+
|
|
525
|
+
describe('when window is on top', () => {
|
|
526
|
+
beforeEach(() => {
|
|
527
|
+
win.top = win;
|
|
528
|
+
cached = cacheWithLocation(fn, win);
|
|
529
|
+
})
|
|
530
|
+
|
|
531
|
+
it('should not cache when canonical URL changes', () => {
|
|
532
|
+
let canonical = 'foo';
|
|
533
|
+
win.document.querySelector.callsFake(() => ({href: canonical}));
|
|
534
|
+
cached();
|
|
535
|
+
expect(cached()).to.eql(RESULT);
|
|
536
|
+
canonical = 'bar';
|
|
537
|
+
expect(cached()).to.eql(RESULT);
|
|
538
|
+
expect(fn.callCount).to.eql(2);
|
|
539
|
+
});
|
|
540
|
+
|
|
541
|
+
it('should not cache when location changes', () => {
|
|
542
|
+
win.location.href = 'foo';
|
|
543
|
+
cached();
|
|
544
|
+
expect(cached()).to.eql(RESULT);
|
|
545
|
+
win.location.href = 'bar';
|
|
546
|
+
expect(cached()).to.eql(RESULT);
|
|
547
|
+
expect(fn.callCount).to.eql(2);
|
|
548
|
+
})
|
|
549
|
+
});
|
|
550
|
+
})
|
|
@@ -52,7 +52,7 @@ describe('Renderer', function () {
|
|
|
52
52
|
expect(testRenderer2.getConfig()).to.deep.equal({ test: 'config2' });
|
|
53
53
|
});
|
|
54
54
|
|
|
55
|
-
it('sets a render function with setRender method', function () {
|
|
55
|
+
it('sets a render function with the setRender method', function () {
|
|
56
56
|
testRenderer1.setRender(spyRenderFn);
|
|
57
57
|
expect(typeof testRenderer1.render).to.equal('function');
|
|
58
58
|
testRenderer1.render();
|
|
@@ -110,7 +110,6 @@ describe('Renderer', function () {
|
|
|
110
110
|
|
|
111
111
|
it('renders immediately when requested', function () {
|
|
112
112
|
const testRenderer3 = Renderer.install({
|
|
113
|
-
url: 'https://httpbin.org/post',
|
|
114
113
|
config: { test: 'config2' },
|
|
115
114
|
id: 2,
|
|
116
115
|
renderNow: true
|
|
@@ -21,6 +21,8 @@ import {find, includes} from 'src/polyfill.js';
|
|
|
21
21
|
import s2sTesting from 'modules/s2sTesting.js';
|
|
22
22
|
import {hook} from '../../../../src/hook.js';
|
|
23
23
|
import {auctionManager} from '../../../../src/auctionManager.js';
|
|
24
|
+
import {GDPR_GVLIDS} from '../../../../src/consentHandler.js';
|
|
25
|
+
import {MODULE_TYPE_ANALYTICS, MODULE_TYPE_BIDDER} from '../../../../src/activities/modules.js';
|
|
24
26
|
var events = require('../../../../src/events');
|
|
25
27
|
|
|
26
28
|
const CONFIG = {
|
|
@@ -1966,64 +1968,6 @@ describe('adapterManager tests', function () {
|
|
|
1966
1968
|
});
|
|
1967
1969
|
});
|
|
1968
1970
|
|
|
1969
|
-
describe('fledgeEnabled', function () {
|
|
1970
|
-
const origRunAdAuction = navigator?.runAdAuction;
|
|
1971
|
-
before(function () {
|
|
1972
|
-
// navigator.runAdAuction doesn't exist, so we can't stub it normally with
|
|
1973
|
-
// sinon.stub(navigator, 'runAdAuction') or something
|
|
1974
|
-
navigator.runAdAuction = sinon.stub();
|
|
1975
|
-
});
|
|
1976
|
-
|
|
1977
|
-
after(function() {
|
|
1978
|
-
navigator.runAdAuction = origRunAdAuction;
|
|
1979
|
-
})
|
|
1980
|
-
|
|
1981
|
-
afterEach(function () {
|
|
1982
|
-
config.resetConfig();
|
|
1983
|
-
});
|
|
1984
|
-
|
|
1985
|
-
it('should set fledgeEnabled correctly per bidder', function () {
|
|
1986
|
-
config.setConfig({bidderSequence: 'fixed'})
|
|
1987
|
-
config.setBidderConfig({
|
|
1988
|
-
bidders: ['appnexus'],
|
|
1989
|
-
config: {
|
|
1990
|
-
fledgeEnabled: true,
|
|
1991
|
-
}
|
|
1992
|
-
});
|
|
1993
|
-
|
|
1994
|
-
const adUnits = [{
|
|
1995
|
-
'code': '/19968336/header-bid-tag1',
|
|
1996
|
-
'mediaTypes': {
|
|
1997
|
-
'banner': {
|
|
1998
|
-
'sizes': [[728, 90]]
|
|
1999
|
-
},
|
|
2000
|
-
},
|
|
2001
|
-
'bids': [
|
|
2002
|
-
{
|
|
2003
|
-
'bidder': 'appnexus',
|
|
2004
|
-
},
|
|
2005
|
-
{
|
|
2006
|
-
'bidder': 'rubicon',
|
|
2007
|
-
},
|
|
2008
|
-
]
|
|
2009
|
-
}];
|
|
2010
|
-
|
|
2011
|
-
const bidRequests = adapterManager.makeBidRequests(
|
|
2012
|
-
adUnits,
|
|
2013
|
-
Date.now(),
|
|
2014
|
-
utils.getUniqueIdentifierStr(),
|
|
2015
|
-
function callback() {},
|
|
2016
|
-
[]
|
|
2017
|
-
);
|
|
2018
|
-
|
|
2019
|
-
expect(bidRequests[0].bids[0].bidder).equals('appnexus');
|
|
2020
|
-
expect(bidRequests[0].fledgeEnabled).to.be.true;
|
|
2021
|
-
|
|
2022
|
-
expect(bidRequests[1].bids[0].bidder).equals('rubicon');
|
|
2023
|
-
expect(bidRequests[1].fledgeEnabled).to.be.undefined;
|
|
2024
|
-
});
|
|
2025
|
-
});
|
|
2026
|
-
|
|
2027
1971
|
describe('sizeMapping', function () {
|
|
2028
1972
|
let sandbox;
|
|
2029
1973
|
beforeEach(function () {
|
|
@@ -2795,4 +2739,23 @@ describe('adapterManager tests', function () {
|
|
|
2795
2739
|
})
|
|
2796
2740
|
})
|
|
2797
2741
|
});
|
|
2742
|
+
|
|
2743
|
+
describe('registers GVL IDs', () => {
|
|
2744
|
+
beforeEach(() => {
|
|
2745
|
+
sinon.stub(GDPR_GVLIDS, 'register');
|
|
2746
|
+
});
|
|
2747
|
+
afterEach(() => {
|
|
2748
|
+
GDPR_GVLIDS.register.restore();
|
|
2749
|
+
});
|
|
2750
|
+
|
|
2751
|
+
it('for bid adapters', () => {
|
|
2752
|
+
adapterManager.registerBidAdapter({getSpec: () => ({gvlid: 123}), callBids: sinon.stub()}, 'mock');
|
|
2753
|
+
sinon.assert.calledWith(GDPR_GVLIDS.register, MODULE_TYPE_BIDDER, 'mock', 123);
|
|
2754
|
+
});
|
|
2755
|
+
|
|
2756
|
+
it('for analytics adapters', () => {
|
|
2757
|
+
adapterManager.registerAnalyticsAdapter({adapter: {enableAnalytics: sinon.stub()}, code: 'mock', gvlid: 123});
|
|
2758
|
+
sinon.assert.calledWith(GDPR_GVLIDS.register, MODULE_TYPE_ANALYTICS, 'mock', 123);
|
|
2759
|
+
});
|
|
2760
|
+
});
|
|
2798
2761
|
});
|
|
@@ -1,4 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import {
|
|
2
|
+
newBidder,
|
|
3
|
+
registerBidder,
|
|
4
|
+
preloadBidderMappingFile,
|
|
5
|
+
storage,
|
|
6
|
+
isValid,
|
|
7
|
+
addComponentAuction
|
|
8
|
+
} from 'src/adapters/bidderFactory.js';
|
|
2
9
|
import adapterManager from 'src/adapterManager.js';
|
|
3
10
|
import * as ajax from 'src/ajax.js';
|
|
4
11
|
import { expect } from 'chai';
|
|
@@ -1212,16 +1219,27 @@ describe('validate bid response: ', function () {
|
|
|
1212
1219
|
};
|
|
1213
1220
|
const fledgeAuctionConfig = {
|
|
1214
1221
|
bidId: '1',
|
|
1222
|
+
config: {
|
|
1223
|
+
foo: 'bar'
|
|
1224
|
+
}
|
|
1215
1225
|
}
|
|
1216
1226
|
describe('when response has FLEDGE auction config', function() {
|
|
1217
|
-
let
|
|
1227
|
+
let fledgeStub;
|
|
1218
1228
|
|
|
1219
|
-
|
|
1220
|
-
|
|
1229
|
+
function fledgeHook(next, ...args) {
|
|
1230
|
+
fledgeStub(...args);
|
|
1231
|
+
}
|
|
1232
|
+
|
|
1233
|
+
before(() => {
|
|
1234
|
+
addComponentAuction.before(fledgeHook);
|
|
1221
1235
|
});
|
|
1222
1236
|
|
|
1223
|
-
|
|
1224
|
-
|
|
1237
|
+
after(() => {
|
|
1238
|
+
addComponentAuction.getHooks({hook: fledgeHook}).remove();
|
|
1239
|
+
})
|
|
1240
|
+
|
|
1241
|
+
beforeEach(function () {
|
|
1242
|
+
fledgeStub = sinon.stub();
|
|
1225
1243
|
});
|
|
1226
1244
|
|
|
1227
1245
|
it('should unwrap bids', function() {
|
|
@@ -1243,8 +1261,8 @@ describe('validate bid response: ', function () {
|
|
|
1243
1261
|
});
|
|
1244
1262
|
bidder.callBids(bidRequest, addBidResponseStub, doneStub, ajaxStub, onTimelyResponseStub, wrappedCallback);
|
|
1245
1263
|
|
|
1246
|
-
expect(
|
|
1247
|
-
|
|
1264
|
+
expect(fledgeStub.calledOnce).to.equal(true);
|
|
1265
|
+
sinon.assert.calledWith(fledgeStub, 'mock/placement', fledgeAuctionConfig.config);
|
|
1248
1266
|
expect(addBidResponseStub.calledOnce).to.equal(true);
|
|
1249
1267
|
expect(addBidResponseStub.firstCall.args[0]).to.equal('mock/placement');
|
|
1250
1268
|
})
|
|
@@ -1257,8 +1275,8 @@ describe('validate bid response: ', function () {
|
|
|
1257
1275
|
});
|
|
1258
1276
|
bidder.callBids(bidRequest, addBidResponseStub, doneStub, ajaxStub, onTimelyResponseStub, wrappedCallback);
|
|
1259
1277
|
|
|
1260
|
-
expect(
|
|
1261
|
-
|
|
1278
|
+
expect(fledgeStub.calledOnce).to.be.true;
|
|
1279
|
+
sinon.assert.calledWith(fledgeStub, 'mock/placement', fledgeAuctionConfig.config);
|
|
1262
1280
|
expect(addBidResponseStub.calledOnce).to.equal(false);
|
|
1263
1281
|
})
|
|
1264
1282
|
})
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {ConsentHandler} from '../../../../src/consentHandler.js';
|
|
1
|
+
import {ConsentHandler, gvlidRegistry} from '../../../../src/consentHandler.js';
|
|
2
2
|
|
|
3
3
|
describe('Consent data handler', () => {
|
|
4
4
|
let handler;
|
|
@@ -57,3 +57,31 @@ describe('Consent data handler', () => {
|
|
|
57
57
|
})
|
|
58
58
|
});
|
|
59
59
|
})
|
|
60
|
+
|
|
61
|
+
describe('gvlidRegistry', () => {
|
|
62
|
+
let registry;
|
|
63
|
+
beforeEach(() => {
|
|
64
|
+
registry = gvlidRegistry();
|
|
65
|
+
});
|
|
66
|
+
|
|
67
|
+
it('returns undef when id cannoot be found', () => {
|
|
68
|
+
expect(registry.get('name')).to.eql({modules: {}})
|
|
69
|
+
});
|
|
70
|
+
|
|
71
|
+
it('does not register null ids', () => {
|
|
72
|
+
registry.register('type', 'name', null);
|
|
73
|
+
expect(registry.get('type', 'name')).to.eql({modules: {}});
|
|
74
|
+
})
|
|
75
|
+
|
|
76
|
+
it('can retrieve registered GVL IDs', () => {
|
|
77
|
+
registry.register('type', 'name', 123);
|
|
78
|
+
registry.register('otherType', 'name', 123);
|
|
79
|
+
expect(registry.get('name')).to.eql({gvlid: 123, modules: {type: 123, otherType: 123}});
|
|
80
|
+
});
|
|
81
|
+
|
|
82
|
+
it('does not return `gvlid` if there is more than one', () => {
|
|
83
|
+
registry.register('type', 'name', 123);
|
|
84
|
+
registry.register('otherType', 'name', 321);
|
|
85
|
+
expect(registry.get('name')).to.eql({modules: {type: 123, otherType: 321}})
|
|
86
|
+
});
|
|
87
|
+
})
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import {
|
|
2
|
+
getCoreStorageManager, getStorageManager,
|
|
3
|
+
newStorageManager,
|
|
2
4
|
resetData,
|
|
3
|
-
getCoreStorageManager,
|
|
4
5
|
storageCallbacks,
|
|
5
|
-
|
|
6
|
-
newStorageManager, validateStorageEnforcement
|
|
6
|
+
validateStorageEnforcement
|
|
7
7
|
} from 'src/storageManager.js';
|
|
8
|
-
import {
|
|
8
|
+
import {config} from 'src/config.js';
|
|
9
9
|
import * as utils from 'src/utils.js';
|
|
10
10
|
import {hook} from '../../../../src/hook.js';
|
|
11
|
-
import {
|
|
11
|
+
import {MODULE_TYPE_BIDDER} from '../../../../src/activities/modules.js';
|
|
12
12
|
|
|
13
13
|
describe('storage manager', function() {
|
|
14
14
|
before(() => {
|
|
@@ -34,7 +34,7 @@ describe('storage manager', function() {
|
|
|
34
34
|
|
|
35
35
|
it('should add done callbacks to storageCallbacks array', function() {
|
|
36
36
|
let noop = sinon.spy();
|
|
37
|
-
const coreStorage =
|
|
37
|
+
const coreStorage = newStorageManager();
|
|
38
38
|
|
|
39
39
|
coreStorage.setCookie('foo', 'bar', null, null, null, noop);
|
|
40
40
|
coreStorage.getCookie('foo', noop);
|
|
@@ -50,17 +50,16 @@ describe('storage manager', function() {
|
|
|
50
50
|
|
|
51
51
|
it('should allow bidder to access device if gdpr enforcement module is not included', function() {
|
|
52
52
|
let deviceAccessSpy = sinon.spy(utils, 'hasDeviceAccess');
|
|
53
|
-
const storage =
|
|
53
|
+
const storage = newStorageManager();
|
|
54
54
|
storage.setCookie('foo1', 'baz1');
|
|
55
55
|
expect(deviceAccessSpy.calledOnce).to.equal(true);
|
|
56
56
|
deviceAccessSpy.restore();
|
|
57
57
|
});
|
|
58
58
|
|
|
59
|
-
describe(`
|
|
60
|
-
let
|
|
59
|
+
describe(`enforcement`, () => {
|
|
60
|
+
let validateHook;
|
|
61
61
|
|
|
62
62
|
beforeEach(() => {
|
|
63
|
-
storage = getCoreStorageManager();
|
|
64
63
|
validateHook = sinon.stub().callsFake(function (next, ...args) {
|
|
65
64
|
next.apply(this, args);
|
|
66
65
|
});
|
|
@@ -72,15 +71,26 @@ describe('storage manager', function() {
|
|
|
72
71
|
config.resetConfig();
|
|
73
72
|
})
|
|
74
73
|
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
})
|
|
74
|
+
Object.entries({
|
|
75
|
+
'core': () => getCoreStorageManager('mock'),
|
|
76
|
+
'other': () => getStorageManager({moduleType: 'other', moduleName: 'mock'})
|
|
77
|
+
}).forEach(([moduleType, getMgr]) => {
|
|
78
|
+
describe(`for ${moduleType} modules`, () => {
|
|
79
|
+
let storage;
|
|
80
|
+
beforeEach(() => {
|
|
81
|
+
storage = getMgr();
|
|
82
|
+
});
|
|
83
|
+
it(`should pass '${moduleType}' module type to consent enforcement`, () => {
|
|
84
|
+
storage.localStorageIsEnabled();
|
|
85
|
+
expect(validateHook.args[0][1]).to.equal(moduleType);
|
|
86
|
+
});
|
|
79
87
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
88
|
+
it('should respect the deviceAccess flag', () => {
|
|
89
|
+
config.setConfig({deviceAccess: false});
|
|
90
|
+
expect(storage.localStorageIsEnabled()).to.be.false
|
|
91
|
+
});
|
|
92
|
+
});
|
|
93
|
+
});
|
|
84
94
|
})
|
|
85
95
|
|
|
86
96
|
describe('localstorage forbidden access in 3rd-party context', function() {
|
|
@@ -100,7 +110,7 @@ describe('storage manager', function() {
|
|
|
100
110
|
})
|
|
101
111
|
|
|
102
112
|
it('should not throw if the localstorage is not accessible when setting/getting/removing from localstorage', function() {
|
|
103
|
-
const coreStorage =
|
|
113
|
+
const coreStorage = newStorageManager();
|
|
104
114
|
|
|
105
115
|
coreStorage.setDataInLocalStorage('key', 'value');
|
|
106
116
|
const val = coreStorage.getDataFromLocalStorage('key');
|
|
@@ -124,7 +134,7 @@ describe('storage manager', function() {
|
|
|
124
134
|
})
|
|
125
135
|
|
|
126
136
|
it('should remove side-effect after checking', function () {
|
|
127
|
-
const storage =
|
|
137
|
+
const storage = newStorageManager();
|
|
128
138
|
|
|
129
139
|
localStorage.setItem('unrelated', 'dummy');
|
|
130
140
|
const val = storage.localStorageIsEnabled();
|
|
@@ -206,7 +216,7 @@ describe('storage manager', function() {
|
|
|
206
216
|
let mgr;
|
|
207
217
|
|
|
208
218
|
beforeEach(() => {
|
|
209
|
-
mgr = newStorageManager({
|
|
219
|
+
mgr = newStorageManager({moduleType: MODULE_TYPE_BIDDER, moduleName: bidderCode}, {bidderSettings: mockBidderSettings(configValue)});
|
|
210
220
|
})
|
|
211
221
|
|
|
212
222
|
afterEach(() => {
|
|
@@ -110,9 +110,10 @@ describe('user sync', function () {
|
|
|
110
110
|
expect(insertUserSyncIframeStub.getCall(0).args[0]).to.equal('http://example.com/iframe');
|
|
111
111
|
});
|
|
112
112
|
|
|
113
|
-
it('should
|
|
113
|
+
it('should stop triggering user syncs after bidderDone', function () {
|
|
114
114
|
const userSync = newTestUserSync({ pixelEnabled: true });
|
|
115
115
|
userSync.registerSync('image', 'testBidder', 'http://example.com/1');
|
|
116
|
+
userSync.bidderDone('testBidder');
|
|
116
117
|
userSync.syncUsers();
|
|
117
118
|
userSync.registerSync('image', 'testBidder', 'http://example.com/2');
|
|
118
119
|
userSync.registerSync('image', 'testBidder2', 'http://example.com/3');
|