prebid.js 9.26.0 → 9.28.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/creative/renderers/native/renderer.js +29 -8
- package/dist/33acrossAnalyticsAdapter.js +1 -1
- package/dist/33acrossBidAdapter.js +1 -1
- package/dist/33acrossIdSystem.js +1 -1
- package/dist/BTBidAdapter.js +1 -1
- package/dist/acuityadsBidAdapter.js +1 -1
- package/dist/adagioAnalyticsAdapter.js +1 -1
- package/dist/adagioBidAdapter.js +1 -1
- package/dist/adagioRtdProvider.js +1 -1
- package/dist/adagioUtils.js +1 -1
- package/dist/addefendBidAdapter.js +1 -1
- package/dist/adgenerationBidAdapter.js +1 -1
- package/dist/adlooxAdServerVideo.js +1 -1
- package/dist/adlooxAnalyticsAdapter.js +1 -1
- package/dist/adlooxRtdProvider.js +1 -1
- package/dist/adqueryBidAdapter.js +1 -1
- package/dist/adrelevantisBidAdapter.js +1 -1
- package/dist/adstirBidAdapter.js +1 -1
- package/dist/adtrgtmeBidAdapter.js +1 -1
- package/dist/adxcgAnalyticsAdapter.js +1 -1
- package/dist/adxcgBidAdapter.js +1 -1
- package/dist/adyoulikeBidAdapter.js +1 -1
- package/dist/agmaAnalyticsAdapter.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/aniviewBidAdapter.js +1 -1
- package/dist/appierAnalyticsAdapter.js +1 -1
- package/dist/appnexusBidAdapter.js +1 -1
- package/dist/asoBidAdapter.js +1 -1
- package/dist/axonixBidAdapter.js +1 -1
- package/dist/bidglassBidAdapter.js +1 -1
- package/dist/big-richmediaBidAdapter.js +1 -1
- package/dist/bitmediaBidAdapter.js +1 -1
- package/dist/blueBidAdapter.js +1 -0
- package/dist/bridBidAdapter.js +1 -1
- package/dist/bridgeuppBidAdapter.js +1 -1
- package/dist/bridgewellBidAdapter.js +1 -1
- package/dist/brightMountainMediaBidAdapter.js +1 -1
- package/dist/carodaBidAdapter.js +1 -1
- package/dist/chtnwBidAdapter.js +1 -1
- package/dist/chunk-core.js +1 -1
- package/dist/conceptxBidAdapter.js +1 -1
- package/dist/concertBidAdapter.js +1 -1
- package/dist/connectadBidAdapter.js +1 -1
- package/dist/consumableBidAdapter.js +1 -1
- package/dist/contxtfulBidAdapter.js +1 -1
- package/dist/contxtfulRtdProvider.js +1 -1
- package/dist/conversantAnalyticsAdapter.js +1 -1
- package/dist/conversantBidAdapter.js +1 -1
- package/dist/craftBidAdapter.js +1 -1
- package/dist/creative-renderer-native.js +1 -1
- package/dist/criteoBidAdapter.js +1 -1
- package/dist/cwireBidAdapter.js +1 -1
- package/dist/dailymotionBidAdapter.js +1 -1
- package/dist/dependencies.json +7 -1
- package/dist/dspxBidAdapter.js +1 -1
- package/dist/dxkultureBidAdapter.js +1 -1
- package/dist/eplanningBidAdapter.js +1 -1
- package/dist/equativBidAdapter.js +1 -1
- package/dist/escalaxBidAdapter.js +1 -1
- package/dist/eskimiBidAdapter.js +1 -1
- package/dist/euidIdSystem.js +1 -1
- package/dist/exadsBidAdapter.js +1 -1
- package/dist/feedadBidAdapter.js +1 -1
- package/dist/finativeBidAdapter.js +1 -1
- package/dist/freewheel-sspBidAdapter.js +1 -1
- package/dist/gmosspBidAdapter.js +1 -1
- package/dist/greenbidsAnalyticsAdapter.js +1 -1
- package/dist/greenbidsBidAdapter.js +1 -1
- package/dist/greenbidsRtdProvider.js +1 -1
- package/dist/gridBidAdapter.js +1 -1
- package/dist/gumgumBidAdapter.js +1 -1
- package/dist/h12mediaBidAdapter.js +1 -1
- package/dist/hypelabBidAdapter.js +1 -1
- package/dist/id5AnalyticsAdapter.js +1 -1
- package/dist/id5IdSystem.js +1 -1
- package/dist/imdsBidAdapter.js +1 -1
- package/dist/improvedigitalBidAdapter.js +1 -1
- package/dist/inmobiBidAdapter.js +1 -1
- package/dist/insticatorBidAdapter.js +1 -1
- package/dist/intentIqAnalyticsAdapter.js +1 -1
- package/dist/intentIqConstants.js +1 -1
- 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/kimberliteBidAdapter.js +1 -1
- package/dist/konduitAnalyticsAdapter.js +1 -1
- package/dist/kueezBidAdapter.js +1 -1
- package/dist/lassoBidAdapter.js +1 -1
- package/dist/lifestreetBidAdapter.js +1 -1
- package/dist/liveIntentId.js +1 -1
- package/dist/liveIntentIdSystem.js +1 -1
- package/dist/liveIntentRtdProvider.js +1 -0
- package/dist/logicadBidAdapter.js +1 -1
- package/dist/loglyliftBidAdapter.js +1 -1
- package/dist/luceadBidAdapter.js +1 -1
- package/dist/mabidderBidAdapter.js +1 -1
- package/dist/madsenseBidAdapter.js +1 -1
- package/dist/magniteAnalyticsAdapter.js +1 -1
- package/dist/malltvAnalyticsAdapter.js +1 -1
- package/dist/marsmediaBidAdapter.js +1 -1
- package/dist/mediafuseBidAdapter.js +1 -1
- package/dist/medianetAnalyticsAdapter.js +1 -1
- package/dist/medianetBidAdapter.js +1 -1
- package/dist/mediasquareBidAdapter.js +1 -1
- package/dist/mgidBidAdapter.js +1 -1
- package/dist/minutemediaBidAdapter.js +1 -1
- package/dist/missenaBidAdapter.js +1 -1
- package/dist/mspa.js +1 -1
- package/dist/nativeRendering.js +1 -1
- package/dist/nextMillenniumBidAdapter.js +1 -1
- package/dist/nexx360BidAdapter.js +1 -1
- package/dist/nobidAnalyticsAdapter.js +1 -1
- package/dist/nobidBidAdapter.js +1 -1
- package/dist/not-for-prod/prebid.js +193 -191
- package/dist/oguryBidAdapter.js +1 -1
- package/dist/omsBidAdapter.js +1 -1
- package/dist/onetagBidAdapter.js +1 -1
- package/dist/ooloAnalyticsAdapter.js +1 -1
- package/dist/openwebBidAdapter.js +1 -1
- package/dist/openxBidAdapter.js +1 -1
- package/dist/optidigitalBidAdapter.js +1 -1
- package/dist/orbidderBidAdapter.js +1 -1
- package/dist/orbitsoftBidAdapter.js +1 -1
- package/dist/outbrainBidAdapter.js +1 -1
- package/dist/pixfutureBidAdapter.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/pubxaiAnalyticsAdapter.js +1 -1
- package/dist/pxyzBidAdapter.js +1 -1
- package/dist/quantcastBidAdapter.js +1 -1
- package/dist/readpeakBidAdapter.js +1 -1
- package/dist/relaidoBidAdapter.js +1 -1
- package/dist/retailspotBidAdapter.js +1 -1
- package/dist/rhythmoneBidAdapter.js +1 -1
- package/dist/riseBidAdapter.js +1 -1
- package/dist/riseUtils.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/showheroes-bsBidAdapter.js +1 -1
- package/dist/sizeUtils.js +1 -1
- package/dist/smaatoBidAdapter.js +1 -1
- package/dist/smartadserverBidAdapter.js +1 -1
- package/dist/smartxBidAdapter.js +1 -1
- package/dist/smilewantedBidAdapter.js +1 -1
- package/dist/snigelBidAdapter.js +1 -1
- package/dist/sonobiBidAdapter.js +1 -1
- package/dist/sovrnBidAdapter.js +1 -1
- package/dist/sparteoBidAdapter.js +1 -1
- package/dist/sspBCBidAdapter.js +1 -1
- package/dist/stnBidAdapter.js +1 -1
- package/dist/stvBidAdapter.js +1 -1
- package/dist/sublimeBidAdapter.js +1 -1
- package/dist/symitriDapRtdProvider.js +1 -1
- package/dist/taboolaBidAdapter.js +1 -1
- package/dist/tappxBidAdapter.js +1 -1
- package/dist/targetVideoBidAdapter.js +1 -1
- package/dist/teadsBidAdapter.js +1 -1
- package/dist/terceptAnalyticsAdapter.js +1 -1
- package/dist/themoneytizerBidAdapter.js +1 -1
- package/dist/trionBidAdapter.js +1 -1
- package/dist/tripleliftBidAdapter.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/unrulyBidAdapter.js +1 -1
- package/dist/userId.js +1 -1
- package/dist/vdoaiBidAdapter.js +1 -1
- package/dist/vidazooUtils.js +1 -1
- package/dist/videobyteBidAdapter.js +1 -1
- package/dist/visxBidAdapter.js +1 -1
- package/dist/vuukleBidAdapter.js +1 -1
- package/dist/widespaceBidAdapter.js +1 -1
- package/dist/winrBidAdapter.js +1 -1
- package/dist/wurflRtdProvider.js +1 -1
- package/dist/yahooAdsBidAdapter.js +1 -1
- package/dist/yieldlabBidAdapter.js +1 -1
- package/dist/yieldmoBidAdapter.js +1 -1
- package/dist/yieldoneAnalyticsAdapter.js +1 -1
- package/dist/zeta_global_sspAnalyticsAdapter.js +1 -1
- package/integrationExamples/gpt/liveIntentRtdProviderExample.html +164 -0
- package/integrationExamples/videoModule/jwplayer/bidMarkedAsUsed.html +3 -1
- package/integrationExamples/videoModule/jwplayer/bidRequestScheduling.html +2 -0
- package/integrationExamples/videoModule/jwplayer/bidsBackHandlerOverride.html +2 -0
- package/integrationExamples/videoModule/jwplayer/eventListeners.html +2 -0
- package/integrationExamples/videoModule/jwplayer/eventsUI.html +2 -0
- package/integrationExamples/videoModule/jwplayer/gamAdServerMediation.html +2 -0
- package/integrationExamples/videoModule/jwplayer/mediaMetadata.html +3 -1
- package/integrationExamples/videoModule/jwplayer/playlist.html +3 -1
- package/libraries/creative-renderer-native/renderer.js +1 -1
- package/libraries/intentIqConstants/intentIqConstants.js +1 -1
- package/libraries/liveIntentId/shared.js +18 -5
- package/libraries/mspa/activityControls.js +26 -7
- package/libraries/riseUtils/constants.js +20 -0
- package/libraries/riseUtils/index.js +143 -38
- package/libraries/sizeUtils/sizeUtils.js +25 -0
- package/libraries/vidazooUtils/bidderUtils.js +2 -0
- package/modules/33acrossIdSystem.js +64 -23
- package/modules/33acrossIdSystem.md +2 -1
- package/modules/acuityadsBidAdapter.js +1 -1
- package/modules/adagioRtdProvider.js +15 -9
- package/modules/adlooxAnalyticsAdapter.js +12 -6
- package/modules/blueBidAdapter.js +122 -0
- package/modules/blueBidAdapter.md +28 -0
- package/modules/conceptxBidAdapter.js +2 -0
- package/modules/consumableBidAdapter.js +3 -1
- package/modules/contxtfulBidAdapter.js +25 -13
- package/modules/contxtfulRtdProvider.js +9 -12
- package/modules/eplanningBidAdapter.js +5 -1
- package/modules/equativBidAdapter.js +13 -18
- package/modules/escalaxBidAdapter.js +2 -2
- package/modules/eskimiBidAdapter.js +4 -1
- package/modules/improvedigitalBidAdapter.js +0 -67
- package/modules/intentIqAnalyticsAdapter.js +1 -1
- package/modules/ixBidAdapter.js +7 -1
- package/modules/jwplayerVideoProvider.js +99 -6
- package/modules/liveIntentRtdProvider.js +52 -0
- package/modules/liveIntentRtdProvider.md +45 -0
- package/modules/minutemediaBidAdapter.js +6 -80
- package/modules/minutemediaBidAdapter.md +1 -1
- package/modules/missenaBidAdapter.js +2 -0
- package/modules/nativeRendering.js +2 -1
- package/modules/omsBidAdapter.js +25 -11
- package/modules/omsBidAdapter.md +15 -0
- package/modules/openwebBidAdapter.js +6 -81
- package/modules/openwebBidAdapter.md +1 -1
- package/modules/openxBidAdapter.js +19 -6
- package/modules/openxBidAdapter.md +46 -1
- package/modules/orbitsoftBidAdapter.js +1 -1
- package/modules/permutiveRtdProvider.md +6 -5
- package/modules/pubmaticAnalyticsAdapter.js +61 -19
- package/modules/riseBidAdapter.js +11 -92
- package/modules/riseBidAdapter.md +1 -1
- package/modules/sharedIdSystem.js +9 -3
- package/modules/shinezBidAdapter.js +4 -80
- package/modules/shinezBidAdapter.md +2 -2
- package/modules/stnBidAdapter.js +7 -86
- package/modules/stnBidAdapter.md +1 -1
- package/modules/symitriDapRtdProvider.js +4 -4
- package/modules/symitriDapRtdProvider.md +2 -2
- package/modules/userId/eids.js +32 -5
- package/modules/wurflRtdProvider.js +7 -1
- package/modules/wurflRtdProvider.md +1 -1
- package/modules/yieldlabBidAdapter.js +2 -2
- package/modules/zeta_global_sspAnalyticsAdapter.js +5 -2
- package/package.json +2 -2
- package/src/adapters/bidderFactory.js +7 -6
- package/src/adloader.js +0 -1
- package/src/native.js +6 -3
- package/test/spec/creative/nativeRenderer_spec.js +45 -10
- package/test/spec/libraries/mspa/activityControls_spec.js +63 -9
- package/test/spec/modules/33acrossIdSystem_spec.js +288 -2
- package/test/spec/modules/acuityadsBidAdapter_spec.js +49 -0
- package/test/spec/modules/adagioRtdProvider_spec.js +119 -3
- package/test/spec/modules/adlooxAdServerVideo_spec.js +0 -1
- package/test/spec/modules/adlooxAnalyticsAdapter_spec.js +31 -0
- package/test/spec/modules/blueBidAdapter_spec.js +91 -0
- package/test/spec/modules/consumableBidAdapter_spec.js +42 -0
- package/test/spec/modules/contxtfulRtdProvider_spec.js +37 -2
- package/test/spec/modules/eplanningBidAdapter_spec.js +74 -1
- package/test/spec/modules/equativBidAdapter_spec.js +5 -6
- package/test/spec/modules/excoBidAdapter_spec.js +33 -18
- package/test/spec/modules/illuminBidAdapter_spec.js +33 -18
- package/test/spec/modules/improvedigitalBidAdapter_spec.js +3 -3
- package/test/spec/modules/ixBidAdapter_spec.js +68 -2
- package/test/spec/modules/kueezRtbBidAdapter_spec.js +33 -18
- package/test/spec/modules/liveIntentExternalIdSystem_spec.js +16 -6
- package/test/spec/modules/liveIntentIdMinimalSystem_spec.js +16 -6
- package/test/spec/modules/liveIntentIdSystem_spec.js +49 -6
- package/test/spec/modules/liveIntentRtdProvider_spec.js +116 -0
- package/test/spec/modules/minutemediaBidAdapter_spec.js +126 -6
- package/test/spec/modules/missenaBidAdapter_spec.js +12 -3
- package/test/spec/modules/omsBidAdapter_spec.js +78 -0
- package/test/spec/modules/openwebBidAdapter_spec.js +126 -6
- package/test/spec/modules/openxBidAdapter_spec.js +236 -8
- package/test/spec/modules/pubmaticAnalyticsAdapter_spec.js +29 -36
- package/test/spec/modules/riseBidAdapter_spec.js +126 -6
- package/test/spec/modules/sharedIdSystem_spec.js +25 -1
- package/test/spec/modules/shinezBidAdapter_spec.js +133 -9
- package/test/spec/modules/shinezRtbBidAdapter_spec.js +33 -18
- package/test/spec/modules/stnBidAdapter_spec.js +126 -5
- package/test/spec/modules/symitriDapRtdProvider_spec.js +36 -0
- package/test/spec/modules/tagorasBidAdapter_spec.js +33 -18
- package/test/spec/modules/twistDigitalBidAdapter_spec.js +34 -18
- package/test/spec/modules/userId_spec.js +103 -2
- package/test/spec/modules/vidazooBidAdapter_spec.js +34 -18
- package/test/spec/modules/videoModule/submodules/jwplayerVideoProvider_spec.js +81 -0
- package/test/spec/modules/wurflRtdProvider_spec.js +8 -3
- package/test/spec/modules/yieldlabBidAdapter_spec.js +5 -5
- package/test/spec/modules/zeta_global_sspAnalyticsAdapter_spec.js +3 -2
- package/test/spec/native_spec.js +4 -2
- package/test/spec/unit/core/bidderFactory_spec.js +120 -43
|
@@ -94,6 +94,36 @@ const VIDEO_BID = {
|
|
|
94
94
|
}
|
|
95
95
|
}
|
|
96
96
|
|
|
97
|
+
const ORTB2_DEVICE = {
|
|
98
|
+
sua: {
|
|
99
|
+
'source': 2,
|
|
100
|
+
'platform': {
|
|
101
|
+
'brand': 'Android',
|
|
102
|
+
'version': ['8', '0', '0']
|
|
103
|
+
},
|
|
104
|
+
'browsers': [
|
|
105
|
+
{'brand': 'Not_A Brand', 'version': ['99', '0', '0', '0']},
|
|
106
|
+
{'brand': 'Google Chrome', 'version': ['109', '0', '5414', '119']},
|
|
107
|
+
{'brand': 'Chromium', 'version': ['109', '0', '5414', '119']}
|
|
108
|
+
],
|
|
109
|
+
'mobile': 1,
|
|
110
|
+
'model': 'SM-G955U',
|
|
111
|
+
'bitness': '64',
|
|
112
|
+
'architecture': ''
|
|
113
|
+
},
|
|
114
|
+
w: 980,
|
|
115
|
+
h: 1720,
|
|
116
|
+
dnt: 0,
|
|
117
|
+
ua: 'Mozilla/5.0 (iPhone; CPU iPhone OS 17_4 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/125.0.6422.80 Mobile/15E148 Safari/604.1',
|
|
118
|
+
language: 'en',
|
|
119
|
+
devicetype: 1,
|
|
120
|
+
make: 'Apple',
|
|
121
|
+
model: 'iPhone 12 Pro Max',
|
|
122
|
+
os: 'iOS',
|
|
123
|
+
osv: '17.4',
|
|
124
|
+
ext: {fiftyonedegrees_deviceId: '17595-133085-133468-18092'},
|
|
125
|
+
};
|
|
126
|
+
|
|
97
127
|
const BIDDER_REQUEST = {
|
|
98
128
|
'gdprConsent': {
|
|
99
129
|
'consentString': 'consent_string',
|
|
@@ -117,24 +147,7 @@ const BIDDER_REQUEST = {
|
|
|
117
147
|
'gpp_sid': [7],
|
|
118
148
|
'coppa': 0
|
|
119
149
|
},
|
|
120
|
-
'device':
|
|
121
|
-
'sua': {
|
|
122
|
-
'source': 2,
|
|
123
|
-
'platform': {
|
|
124
|
-
'brand': 'Android',
|
|
125
|
-
'version': ['8', '0', '0']
|
|
126
|
-
},
|
|
127
|
-
'browsers': [
|
|
128
|
-
{'brand': 'Not_A Brand', 'version': ['99', '0', '0', '0']},
|
|
129
|
-
{'brand': 'Google Chrome', 'version': ['109', '0', '5414', '119']},
|
|
130
|
-
{'brand': 'Chromium', 'version': ['109', '0', '5414', '119']}
|
|
131
|
-
],
|
|
132
|
-
'mobile': 1,
|
|
133
|
-
'model': 'SM-G955U',
|
|
134
|
-
'bitness': '64',
|
|
135
|
-
'architecture': ''
|
|
136
|
-
}
|
|
137
|
-
}
|
|
150
|
+
'device': ORTB2_DEVICE,
|
|
138
151
|
}
|
|
139
152
|
};
|
|
140
153
|
|
|
@@ -315,6 +328,7 @@ describe('IlluminBidAdapter', function () {
|
|
|
315
328
|
'bitness': '64',
|
|
316
329
|
'architecture': ''
|
|
317
330
|
},
|
|
331
|
+
device: ORTB2_DEVICE,
|
|
318
332
|
uniqueDealId: `${hashUrl}_${Date.now().toString()}`,
|
|
319
333
|
uqs: getTopWindowQueryParams(),
|
|
320
334
|
mediaTypes: {
|
|
@@ -386,6 +400,7 @@ describe('IlluminBidAdapter', function () {
|
|
|
386
400
|
'bitness': '64',
|
|
387
401
|
'architecture': ''
|
|
388
402
|
},
|
|
403
|
+
device: ORTB2_DEVICE,
|
|
389
404
|
url: 'https%3A%2F%2Fwww.greatsite.com',
|
|
390
405
|
referrer: 'https://www.somereferrer.com',
|
|
391
406
|
cb: 1000,
|
|
@@ -1006,7 +1006,7 @@ describe('Improve Digital Adapter Tests', function () {
|
|
|
1006
1006
|
width: 728,
|
|
1007
1007
|
height: 90,
|
|
1008
1008
|
ttl: 300,
|
|
1009
|
-
ad: '
|
|
1009
|
+
ad: '<html><body style="margin:0%"><a href="https://na-ice.360yield.com/click/wIUgWAXQ-Teg9bFreqmjvvwpXD86tInZbesBQgOtGBHqZatmIY9C1mo-1kWRx32zN2mfOxtmyaaHpr.Qh5pspzJarrsm08TtkRSeTc2mnsRuQ2MKzCTvbospesMJR28YLZ.3g06DwS6c5XOJuesd0eODk7GCqtmJ18c6CTmdWDUdDxiknLAPHVXAfvlDH5AA9utF7TNNGjaxvyMpQD51.Dt5GFjcJLnwWnGSajoSr9JfomoGenbLkabLmzylSXd1p9xyrzTmWU39FvagEOZnMb2ixlc.JDxXA1ZnaR.e7ywkwiJnDtg1Om0EJAYOmUh0oTozbXeo26iwLLZxVxV0owOHY61zhHYyHcpBakqtelYPWZcmBJEXfl5KIekB2CiLQqxCi3TKdg5FztAQY0Tf3mTmiGZev0RkeiX5fnxS8jbWSD-cCgB51PNLn0X5EEkUPkOJh9JV713OOcyDhsgaFPezUcvuD7nNrxB71aWcH6MMfk1BFQ7kSVi9WHQvauaTxrWm//https%3A%2F%2Fazerion.com" target="_blank"><img style="border: 0;" border="0" width=728 height=90 src="https://creative.360yield.com/file/241121/728x90.jpg" alt=" "/></a><img src="https://na-ice.360yield.com/imp_pixel?ic=wIUgWDjQ.pQrjtYOEKs44M3pIqNnfojBPkSd3WRdHnRawHiRiER7A-0RowzsOtOLq7MWtEFnWsRXYZZmJcZPGft0cNSs8lNOVZnXWHLDv3Dyqo8VGI4737RieGIK0DrIjlVXzFmuYeXufriRfPHVGiV-hz6VIateQ6I7.xR5O.48..ZoEGfRpIJGzqeqz12cWnFUPhBScQ6sPLlb6B1RiTpNh170OhIVfX80N2g4jn-U.xJ262ND29bBvImQsJjz29o8mmGL3TfbzUHzr.ob-ozfP9.ZHh.B5tD-M5qG9rAlIU6Q7I-zchnhv1W5OzU5mfMYy9yMLKqBemQGJA1KaiZJV79lwnDki-6PIg1v09h86eJqXYHHsUobx4Np5lMT6-5UdHXZPpR8T08b4keLREQw-lpqKum92pwUCVAYPeFdmTeKk1gUKPcaWxN8QfaQeoLJfb.88n3-vp.-aBCkxlZwXjXSd55QV.uwi-bTtFwaZjGHpNkIBG3D19kNl.Yb55Rk" alt=" " style="display:none"/><improvedigital_ad_output_information tp_id="" buyer_id="0" rtb_advertiser="" campaign_id="123159" line_item_id="320896" creative_id="510265" crid="0" placement_id="22135702"></improvedigital_ad_output_information></body></html>',
|
|
1010
1010
|
creativeId: '510265',
|
|
1011
1011
|
dealId: 320896,
|
|
1012
1012
|
netRevenue: false,
|
|
@@ -1016,7 +1016,7 @@ describe('Improve Digital Adapter Tests', function () {
|
|
|
1016
1016
|
|
|
1017
1017
|
const multiFormatExpectedBid = [
|
|
1018
1018
|
Object.assign({}, expectedBid[0], {
|
|
1019
|
-
ad: '
|
|
1019
|
+
ad: '<html><body style="margin:0%"><a href="https://na-ice.360yield.com/click/wIUgWAXQ-Teg9bFreqmjvvwpXD86tInZbesBQgOtGBHqZatmIY9C1mo-1kWRx32zN2mfOxtmyaaHpr.Qh5pspzJarrsm08TtkRSeTc2mnsRuQ2MKzCTvbospesMJR28YLZ.3g06DwS6c5XOJuesd0eODk7GCqtmJ18c6CTmdWDUdDxiknLAPHVXAfvlDH5AA9utF7TNNGjaxvyMpQD51.Dt5GFjcJLnwWnGSajoSr9JfomoGenbLkabLmzylSXd1p9xyrzTmWU39FvagEOZnMb2ixlc.JDxXA1ZnaR.e7ywkwiJnDtg1Om0EJAYOmUh0oTozbXeo26iwLLZxVxV0owOHY61zhHYyHcpBakqtelYPWZcmBJEXfl5KIekB2CiLQqxCi3TKdg5FztAQY0Tf3mTmiGZev0RkeiX5fnxS8jbWSD-cCgB51PNLn0X5EEkUPkOJh9JV713OOcyDhsgaFPezUcvuD7nNrxB71aWcH6MMfk1BFQ7kSVi9WHQvauaTxrWm//https%3A%2F%2Fazerion.com" target="_blank"><img style="border: 0;" border="0" width=728 height=90 src="https://creative.360yield.com/file/241121/728x90.jpg" alt=" "/></a><img src="https://na-ice.360yield.com/imp_pixel?ic=wIUgWDjQ.pQrjtYOEKs44M3pIqNnfojBPkSd3WRdHnRawHiRiER7A-0RowzsOtOLq7MWtEFnWsRXYZZmJcZPGft0cNSs8lNOVZnXWHLDv3Dyqo8VGI4737RieGIK0DrIjlVXzFmuYeXufriRfPHVGiV-hz6VIateQ6I7.xR5O.48..ZoEGfRpIJGzqeqz12cWnFUPhBScQ6sPLlb6B1RiTpNh170OhIVfX80N2g4jn-U.xJ262ND29bBvImQsJjz29o8mmGL3TfbzUHzr.ob-ozfP9.ZHh.B5tD-M5qG9rAlIU6Q7I-zchnhv1W5OzU5mfMYy9yMLKqBemQGJA1KaiZJV79lwnDki-6PIg1v09h86eJqXYHHsUobx4Np5lMT6-5UdHXZPpR8T08b4keLREQw-lpqKum92pwUCVAYPeFdmTeKk1gUKPcaWxN8QfaQeoLJfb.88n3-vp.-aBCkxlZwXjXSd55QV.uwi-bTtFwaZjGHpNkIBG3D19kNl.Yb55Rk" alt=" " style="display:none"/><improvedigital_ad_output_information tp_id="" buyer_id="0" rtb_advertiser="" campaign_id="123159" line_item_id="320896" creative_id="510265" crid="0" placement_id="22135702"></improvedigital_ad_output_information></body></html>',
|
|
1020
1020
|
})
|
|
1021
1021
|
];
|
|
1022
1022
|
|
|
@@ -1029,7 +1029,7 @@ describe('Improve Digital Adapter Tests', function () {
|
|
|
1029
1029
|
width: 300,
|
|
1030
1030
|
height: 250,
|
|
1031
1031
|
ttl: 300,
|
|
1032
|
-
ad: '
|
|
1032
|
+
ad: '<html><body style="margin:0%"><a href="https://na-ice.360yield.com/click/.2RC3VhfEsdhtcsRiT8bWksMTmBbkfnj1AaD3C6Bht.Bp85KK5vjzZvJMpigI4ECdhllWuzbk2UhQt8VEGq1tg8m1OEot7Gs94PplWYs2ESdXpGAPFHiqdbZstOOhfiWL4D.k6lXfgNmbRhpL.SktYeEAiRaOZHQAX.22IEQ0swRnEdNyjHXYEkNIgpvMLqkZTv.JYM.iW9NwyJLIqk4Djh8X301iRLxexGBTl7-.n93WbkSCVY6uwdXSzoQrtK1r3fTrS34rdgpqFt6ZIBLKWI2ByLM2.aQqfvev5BCMOeyEKY8CcSg9SoDiPyQsvcz9bTckLtqs3AD3Qu8I.2rGn1NID7ljgg6-dERrorPK9A5XK67Pv34UqUe2xILQ6wvi52dX4p5d3yxsI9BMfnxzkn7MullVJdn-NiSB2rTe2MFozJc5G1nEwtpsMwZpBxl00PCcMsyETtaKbhqa3Gq5nCuce4AEhL6109IrZscUUzBMSKLSX16HlFfmPZ.gDnWCI3lO35UbGdL7lKjbT9mHYQ-//http%3A%2F%2Fblah.com" target="_blank"><img style="border: 0;" border="0" width=300 height=250 src="https://creative.360yield.com/file/238052/test_ads-300x250.jpg" alt=" "/></a><img src="https://na-ice.360yield.com/imp_pixel?ic=.2RC3VqxeCtOU3G5i6Wejh69dm5JnKlRXeieMtJA63nfGMyuFoWTTjSU5PfHLg2PtnmDRFgHJgGE19QyjAGj6ZQVy0iUk-HF-.zsAlx.7Fx3m5fPE7RIYw.kjy-BvuprFqfU-qlm03KTks6zVLDSIspuxemNQ1HBhq6QZSm9qqAVY-1XS-KbImfb.fll3VvhJXy7Ru.KstgDfAJwt5vYxVab6efvjAIhOrrv6uXaywFVTtu9-gK5pKgIkdixxuYE2jLUyEh9GiRyRCH0jhhUVUmSfrjE4OuTq-7TmCYXQQ5Vk9AqOV.JybF8d35IeyAbF2aywwdZA2SGGEGeYIoOy.7D8TpuVqXxvnUyeKXlCfmzXcJs27W2sKGUTfpWc-TyhAOHKzwqrxP-QN5D1QRCXFWgAm.rwUBguE-oL1Q7NOaCsaRwINRwvQrastWNFUDEYzrB32NL-wIkILdh9e96JwhKiwGwJ1VqH.6RDDutUi9CLreYQl348exTfqL44Ia5VTLn7e0rA6s9V1tg55V7TX36" alt=" " style="display:none"/><improvedigital_ad_output_information tp_id="" buyer_id="0" rtb_advertiser="" campaign_id="123159" line_item_id="320896" creative_id="479163" crid="0" placement_id="22135702"></improvedigital_ad_output_information></body></html>',
|
|
1033
1033
|
creativeId: '479163',
|
|
1034
1034
|
dealId: 320896,
|
|
1035
1035
|
netRevenue: false,
|
|
@@ -4,6 +4,7 @@ import { expect } from 'chai';
|
|
|
4
4
|
import { newBidder } from 'src/adapters/bidderFactory.js';
|
|
5
5
|
import { spec, storage, FEATURE_TOGGLES, LOCAL_STORAGE_FEATURE_TOGGLES_KEY, REQUESTED_FEATURE_TOGGLES, combineImps, bidToVideoImp, bidToNativeImp, deduplicateImpExtFields, removeSiteIDs, addDeviceInfo } from '../../../modules/ixBidAdapter.js';
|
|
6
6
|
import { deepAccess, deepClone } from '../../../src/utils.js';
|
|
7
|
+
import * as ajaxLib from 'src/ajax.js';
|
|
7
8
|
|
|
8
9
|
describe('IndexexchangeAdapter', function () {
|
|
9
10
|
const IX_SECURE_ENDPOINT = 'https://htlb.casalemedia.com/openrtb/pbjs';
|
|
@@ -615,7 +616,8 @@ describe('IndexexchangeAdapter', function () {
|
|
|
615
616
|
dspid: 50,
|
|
616
617
|
pricelevel: '_100',
|
|
617
618
|
advbrandid: 303325,
|
|
618
|
-
advbrand: 'OECTA'
|
|
619
|
+
advbrand: 'OECTA',
|
|
620
|
+
ibv: true
|
|
619
621
|
},
|
|
620
622
|
adm: '<a target="_blank" href="https://www.indexexchange.com"></a>'
|
|
621
623
|
}
|
|
@@ -2088,7 +2090,11 @@ describe('IndexexchangeAdapter', function () {
|
|
|
2088
2090
|
it('request should be made to IX endpoint with POST method and siteId in query param', function () {
|
|
2089
2091
|
expect(requestMethod).to.equal('POST');
|
|
2090
2092
|
expect(requestUrl).to.equal(IX_SECURE_ENDPOINT + '?s=' + DEFAULT_BANNER_VALID_BID[0].params.siteId);
|
|
2091
|
-
|
|
2093
|
+
});
|
|
2094
|
+
|
|
2095
|
+
it('request made to IX endpoint with POST method should have correct options fields set', function () {
|
|
2096
|
+
expect(request.options.contentType).to.equal('text/plain')
|
|
2097
|
+
expect(request.options.withCredentials).to.equal(true)
|
|
2092
2098
|
});
|
|
2093
2099
|
|
|
2094
2100
|
it('auction type should be set correctly', function () {
|
|
@@ -3603,6 +3609,9 @@ describe('IndexexchangeAdapter', function () {
|
|
|
3603
3609
|
brandId: 303325,
|
|
3604
3610
|
brandName: 'OECTA',
|
|
3605
3611
|
advertiserDomains: ['www.abc.com']
|
|
3612
|
+
},
|
|
3613
|
+
ext: {
|
|
3614
|
+
ibv: true
|
|
3606
3615
|
}
|
|
3607
3616
|
}
|
|
3608
3617
|
];
|
|
@@ -3714,6 +3723,9 @@ describe('IndexexchangeAdapter', function () {
|
|
|
3714
3723
|
brandId: 303325,
|
|
3715
3724
|
brandName: 'OECTA',
|
|
3716
3725
|
advertiserDomains: ['www.abc.com']
|
|
3726
|
+
},
|
|
3727
|
+
ext: {
|
|
3728
|
+
ibv: true
|
|
3717
3729
|
}
|
|
3718
3730
|
}
|
|
3719
3731
|
];
|
|
@@ -3770,6 +3782,9 @@ describe('IndexexchangeAdapter', function () {
|
|
|
3770
3782
|
brandId: 303325,
|
|
3771
3783
|
brandName: 'OECTA',
|
|
3772
3784
|
advertiserDomains: ['www.abc.com']
|
|
3785
|
+
},
|
|
3786
|
+
ext: {
|
|
3787
|
+
ibv: true
|
|
3773
3788
|
}
|
|
3774
3789
|
}
|
|
3775
3790
|
];
|
|
@@ -5003,6 +5018,7 @@ describe('IndexexchangeAdapter', function () {
|
|
|
5003
5018
|
expect(result['b8c6b5d5-76a1-4a90-b635-0c7eae1bfaa7'].ixImps.length).to.equal(1);
|
|
5004
5019
|
});
|
|
5005
5020
|
});
|
|
5021
|
+
|
|
5006
5022
|
describe('apply floors test', function () {
|
|
5007
5023
|
it('video test', function() {
|
|
5008
5024
|
const bid = utils.deepClone(DEFAULT_VIDEO_VALID_BID[0]);
|
|
@@ -5367,6 +5383,7 @@ describe('IndexexchangeAdapter', function () {
|
|
|
5367
5383
|
expect(removeSiteIDs(request)).to.deep.equal(expected);
|
|
5368
5384
|
});
|
|
5369
5385
|
});
|
|
5386
|
+
|
|
5370
5387
|
describe('addDeviceInfo', () => {
|
|
5371
5388
|
it('should add device to request when device already exists', () => {
|
|
5372
5389
|
let r = {
|
|
@@ -5385,4 +5402,53 @@ describe('IndexexchangeAdapter', function () {
|
|
|
5385
5402
|
expect(r.device.h).to.exist;
|
|
5386
5403
|
});
|
|
5387
5404
|
});
|
|
5405
|
+
|
|
5406
|
+
describe('fetch requests', function () {
|
|
5407
|
+
let ajaxStub;
|
|
5408
|
+
|
|
5409
|
+
beforeEach(function () {
|
|
5410
|
+
ajaxStub = sinon.stub(ajaxLib, 'ajaxBuilder').callsFake(() => {
|
|
5411
|
+
return sinon.spy(function (url, callback, data, options) {
|
|
5412
|
+
callback.success('OK');
|
|
5413
|
+
});
|
|
5414
|
+
});
|
|
5415
|
+
});
|
|
5416
|
+
|
|
5417
|
+
afterEach(function () {
|
|
5418
|
+
ajaxStub.restore();
|
|
5419
|
+
});
|
|
5420
|
+
|
|
5421
|
+
it('should send the correct headers in the actual fetch call', function (done) {
|
|
5422
|
+
const requests = spec.buildRequests(DEFAULT_BANNER_VALID_BID, DEFAULT_OPTION);
|
|
5423
|
+
const request = requests[0];
|
|
5424
|
+
const ajax = ajaxLib.ajaxBuilder();
|
|
5425
|
+
|
|
5426
|
+
ajax(
|
|
5427
|
+
request.url,
|
|
5428
|
+
{
|
|
5429
|
+
success: () => {
|
|
5430
|
+
try {
|
|
5431
|
+
sinon.assert.calledOnce(ajaxStub);
|
|
5432
|
+
const ajaxCall = ajaxStub.returnValues[0];
|
|
5433
|
+
sinon.assert.calledOnce(ajaxCall);
|
|
5434
|
+
const [calledUrl, callback, calledData, calledOptions] = ajaxCall.getCall(0).args;
|
|
5435
|
+
|
|
5436
|
+
expect(calledUrl).to.equal(request.url);
|
|
5437
|
+
expect(calledData).to.equal(request.data);
|
|
5438
|
+
|
|
5439
|
+
expect(calledOptions.contentType).to.equal('text/plain');
|
|
5440
|
+
expect(calledOptions.withCredentials).to.be.true;
|
|
5441
|
+
|
|
5442
|
+
done();
|
|
5443
|
+
} catch (err) {
|
|
5444
|
+
done(err);
|
|
5445
|
+
}
|
|
5446
|
+
},
|
|
5447
|
+
error: (err) => done(err || new Error('Ajax request failed')),
|
|
5448
|
+
},
|
|
5449
|
+
request.data,
|
|
5450
|
+
request.options
|
|
5451
|
+
);
|
|
5452
|
+
});
|
|
5453
|
+
});
|
|
5388
5454
|
});
|
|
@@ -93,6 +93,36 @@ const VIDEO_BID = {
|
|
|
93
93
|
}
|
|
94
94
|
}
|
|
95
95
|
|
|
96
|
+
const ORTB2_DEVICE = {
|
|
97
|
+
sua: {
|
|
98
|
+
'source': 2,
|
|
99
|
+
'platform': {
|
|
100
|
+
'brand': 'Android',
|
|
101
|
+
'version': ['8', '0', '0']
|
|
102
|
+
},
|
|
103
|
+
'browsers': [
|
|
104
|
+
{'brand': 'Not_A Brand', 'version': ['99', '0', '0', '0']},
|
|
105
|
+
{'brand': 'Google Chrome', 'version': ['109', '0', '5414', '119']},
|
|
106
|
+
{'brand': 'Chromium', 'version': ['109', '0', '5414', '119']}
|
|
107
|
+
],
|
|
108
|
+
'mobile': 1,
|
|
109
|
+
'model': 'SM-G955U',
|
|
110
|
+
'bitness': '64',
|
|
111
|
+
'architecture': ''
|
|
112
|
+
},
|
|
113
|
+
w: 980,
|
|
114
|
+
h: 1720,
|
|
115
|
+
dnt: 0,
|
|
116
|
+
ua: 'Mozilla/5.0 (iPhone; CPU iPhone OS 17_4 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/125.0.6422.80 Mobile/15E148 Safari/604.1',
|
|
117
|
+
language: 'en',
|
|
118
|
+
devicetype: 1,
|
|
119
|
+
make: 'Apple',
|
|
120
|
+
model: 'iPhone 12 Pro Max',
|
|
121
|
+
os: 'iOS',
|
|
122
|
+
osv: '17.4',
|
|
123
|
+
ext: {fiftyonedegrees_deviceId: '17595-133085-133468-18092'},
|
|
124
|
+
};
|
|
125
|
+
|
|
96
126
|
const BIDDER_REQUEST = {
|
|
97
127
|
'gdprConsent': {
|
|
98
128
|
'consentString': 'consent_string',
|
|
@@ -116,24 +146,7 @@ const BIDDER_REQUEST = {
|
|
|
116
146
|
'gpp_sid': [7],
|
|
117
147
|
'coppa': 0
|
|
118
148
|
},
|
|
119
|
-
'device':
|
|
120
|
-
'sua': {
|
|
121
|
-
'source': 2,
|
|
122
|
-
'platform': {
|
|
123
|
-
'brand': 'Android',
|
|
124
|
-
'version': ['8', '0', '0']
|
|
125
|
-
},
|
|
126
|
-
'browsers': [
|
|
127
|
-
{'brand': 'Not_A Brand', 'version': ['99', '0', '0', '0']},
|
|
128
|
-
{'brand': 'Google Chrome', 'version': ['109', '0', '5414', '119']},
|
|
129
|
-
{'brand': 'Chromium', 'version': ['109', '0', '5414', '119']}
|
|
130
|
-
],
|
|
131
|
-
'mobile': 1,
|
|
132
|
-
'model': 'SM-G955U',
|
|
133
|
-
'bitness': '64',
|
|
134
|
-
'architecture': ''
|
|
135
|
-
}
|
|
136
|
-
}
|
|
149
|
+
'device': ORTB2_DEVICE,
|
|
137
150
|
}
|
|
138
151
|
};
|
|
139
152
|
|
|
@@ -321,6 +334,7 @@ describe('KueezRtbBidAdapter', function () {
|
|
|
321
334
|
'bitness': '64',
|
|
322
335
|
'architecture': ''
|
|
323
336
|
},
|
|
337
|
+
device: ORTB2_DEVICE,
|
|
324
338
|
uniqueDealId: `${hashUrl}_${Date.now().toString()}`,
|
|
325
339
|
uqs: getTopWindowQueryParams(),
|
|
326
340
|
mediaTypes: {
|
|
@@ -394,6 +408,7 @@ describe('KueezRtbBidAdapter', function () {
|
|
|
394
408
|
'bitness': '64',
|
|
395
409
|
'architecture': ''
|
|
396
410
|
},
|
|
411
|
+
device: ORTB2_DEVICE,
|
|
397
412
|
url: 'https%3A%2F%2Fwww.greatsite.com',
|
|
398
413
|
referrer: 'https://www.somereferrer.com',
|
|
399
414
|
cb: 1000,
|
|
@@ -269,11 +269,6 @@ describe('LiveIntentExternalId', function() {
|
|
|
269
269
|
expect(window.liQHub).to.have.length(1) // instead of 2
|
|
270
270
|
});
|
|
271
271
|
|
|
272
|
-
it('should not return a decoded identifier when the unifiedId is not present in the value', function() {
|
|
273
|
-
const result = liveIntentExternalIdSubmodule.decode({ fireEventDelay: 1, additionalData: 'data' });
|
|
274
|
-
expect(result).to.be.eql({});
|
|
275
|
-
});
|
|
276
|
-
|
|
277
272
|
it('should decode a unifiedId to lipbId and remove it', function() {
|
|
278
273
|
const result = liveIntentExternalIdSubmodule.decode({ unifiedId: 'data' }, defaultConfigParams);
|
|
279
274
|
expect(result).to.eql({'lipb': {'lipbid': 'data'}});
|
|
@@ -316,6 +311,11 @@ describe('LiveIntentExternalId', function() {
|
|
|
316
311
|
})
|
|
317
312
|
});
|
|
318
313
|
|
|
314
|
+
it('should decode values with the segments but no nonId', function() {
|
|
315
|
+
const result = liveIntentExternalIdSubmodule.decode({segments: ['tak']}, { params: defaultConfigParams });
|
|
316
|
+
expect(result).to.eql({'lipb': {'segments': ['tak']}});
|
|
317
|
+
});
|
|
318
|
+
|
|
319
319
|
it('should decode a uid2 to a separate object when present', function() {
|
|
320
320
|
const result = liveIntentExternalIdSubmodule.decode({ nonId: 'foo', uid2: 'bar' }, defaultConfigParams);
|
|
321
321
|
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'uid2': 'bar'}, 'uid2': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
@@ -323,7 +323,7 @@ describe('LiveIntentExternalId', function() {
|
|
|
323
323
|
|
|
324
324
|
it('should decode values with uid2 but no nonId', function() {
|
|
325
325
|
const result = liveIntentExternalIdSubmodule.decode({ uid2: 'bar' }, defaultConfigParams);
|
|
326
|
-
expect(result).to.eql({'uid2': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
326
|
+
expect(result).to.eql({'lipb': {'uid2': 'bar'}, 'uid2': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
327
327
|
});
|
|
328
328
|
|
|
329
329
|
it('should decode a bidswitch id to a separate object when present', function() {
|
|
@@ -456,8 +456,18 @@ describe('LiveIntentExternalId', function() {
|
|
|
456
456
|
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'sonobi': 'bar'}, 'sonobi': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
457
457
|
});
|
|
458
458
|
|
|
459
|
+
it('should decode a triplelift id to a separate object when present', function() {
|
|
460
|
+
const result = liveIntentExternalIdSubmodule.decode({ nonId: 'foo', triplelift: 'bar' }, defaultConfigParams);
|
|
461
|
+
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'triplelift': 'bar'}, 'triplelift': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
462
|
+
});
|
|
463
|
+
|
|
459
464
|
it('should decode a vidazoo id to a separate object when present', function() {
|
|
460
465
|
const result = liveIntentExternalIdSubmodule.decode({ nonId: 'foo', vidazoo: 'bar' }, defaultConfigParams);
|
|
461
466
|
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'vidazoo': 'bar'}, 'vidazoo': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
462
467
|
});
|
|
468
|
+
|
|
469
|
+
it('should decode the segments as part of lipb', function() {
|
|
470
|
+
const result = liveIntentExternalIdSubmodule.decode({ nonId: 'foo', 'segments': ['bar'] }, { params: defaultConfigParams });
|
|
471
|
+
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'segments': ['bar']}});
|
|
472
|
+
});
|
|
463
473
|
});
|
|
@@ -49,11 +49,6 @@ describe('LiveIntentMinimalId', function() {
|
|
|
49
49
|
expect(server.requests[0]).to.eql(undefined)
|
|
50
50
|
});
|
|
51
51
|
|
|
52
|
-
it('should not return a decoded identifier when the unifiedId is not present in the value', function() {
|
|
53
|
-
const result = liveIntentIdSubmodule.decode({ additionalData: 'data' });
|
|
54
|
-
expect(result).to.be.eql({});
|
|
55
|
-
});
|
|
56
|
-
|
|
57
52
|
it('should initialize LiveConnect and send no data', function() {
|
|
58
53
|
liveIntentIdSubmodule.getId(defaultConfigParams);
|
|
59
54
|
liveIntentIdSubmodule.decode({}, defaultConfigParams);
|
|
@@ -245,6 +240,11 @@ describe('LiveIntentMinimalId', function() {
|
|
|
245
240
|
expect(callBackSpy.calledOnce).to.be.true;
|
|
246
241
|
});
|
|
247
242
|
|
|
243
|
+
it('should decode values with the segments but no nonId', function() {
|
|
244
|
+
const result = liveIntentIdSubmodule.decode({segments: ['tak']}, { params: defaultConfigParams });
|
|
245
|
+
expect(result).to.eql({'lipb': {'segments': ['tak']}});
|
|
246
|
+
});
|
|
247
|
+
|
|
248
248
|
it('should decode a uid2 to a separate object when present', function() {
|
|
249
249
|
const result = liveIntentIdSubmodule.decode({ nonId: 'foo', uid2: 'bar' });
|
|
250
250
|
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'uid2': 'bar'}, 'uid2': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
@@ -252,7 +252,7 @@ describe('LiveIntentMinimalId', function() {
|
|
|
252
252
|
|
|
253
253
|
it('should decode values with uid2 but no nonId', function() {
|
|
254
254
|
const result = liveIntentIdSubmodule.decode({ uid2: 'bar' });
|
|
255
|
-
expect(result).to.eql({'uid2': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
255
|
+
expect(result).to.eql({'lipb': {'uid2': 'bar'}, 'uid2': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
256
256
|
});
|
|
257
257
|
|
|
258
258
|
it('should decode a bidswitch id to a separate object when present', function() {
|
|
@@ -324,8 +324,18 @@ describe('LiveIntentMinimalId', function() {
|
|
|
324
324
|
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'sonobi': 'bar'}, 'sonobi': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
325
325
|
});
|
|
326
326
|
|
|
327
|
+
it('should decode a triplelift id to a separate object when present', function() {
|
|
328
|
+
const result = liveIntentIdSubmodule.decode({ nonId: 'foo', triplelift: 'bar' }, defaultConfigParams);
|
|
329
|
+
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'triplelift': 'bar'}, 'triplelift': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
330
|
+
});
|
|
331
|
+
|
|
327
332
|
it('should decode a vidazoo id to a separate object when present', function() {
|
|
328
333
|
const result = liveIntentIdSubmodule.decode({ nonId: 'foo', vidazoo: 'bar' });
|
|
329
334
|
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'vidazoo': 'bar'}, 'vidazoo': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
330
335
|
});
|
|
336
|
+
|
|
337
|
+
it('should decode the segments as part of lipb', function() {
|
|
338
|
+
const result = liveIntentIdSubmodule.decode({ nonId: 'foo', 'segments': ['bar'] }, { params: defaultConfigParams });
|
|
339
|
+
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'segments': ['bar']}});
|
|
340
|
+
});
|
|
331
341
|
});
|
|
@@ -188,11 +188,6 @@ describe('LiveIntentId', function() {
|
|
|
188
188
|
}, 300);
|
|
189
189
|
});
|
|
190
190
|
|
|
191
|
-
it('should not return a decoded identifier when the unifiedId is not present in the value', function() {
|
|
192
|
-
const result = liveIntentIdSubmodule.decode({ params: { fireEventDelay: 1, additionalData: 'data' } });
|
|
193
|
-
expect(result).to.be.eql({});
|
|
194
|
-
});
|
|
195
|
-
|
|
196
191
|
it('should fire an event when decode', function(done) {
|
|
197
192
|
liveIntentIdSubmodule.decode({}, { params: defaultConfigParams });
|
|
198
193
|
setTimeout(() => {
|
|
@@ -422,9 +417,14 @@ describe('LiveIntentId', function() {
|
|
|
422
417
|
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'uid2': 'bar'}, 'uid2': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
423
418
|
});
|
|
424
419
|
|
|
420
|
+
it('should decode values with the segments but no nonId', function() {
|
|
421
|
+
const result = liveIntentIdSubmodule.decode({segments: ['tak']}, { params: defaultConfigParams });
|
|
422
|
+
expect(result).to.eql({'lipb': {'segments': ['tak']}});
|
|
423
|
+
});
|
|
424
|
+
|
|
425
425
|
it('should decode values with uid2 but no nonId', function() {
|
|
426
426
|
const result = liveIntentIdSubmodule.decode({ uid2: 'bar' }, { params: defaultConfigParams });
|
|
427
|
-
expect(result).to.eql({'uid2': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
427
|
+
expect(result).to.eql({'lipb': {'uid2': 'bar'}, 'uid2': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
428
428
|
});
|
|
429
429
|
|
|
430
430
|
it('should decode a bidswitch id to a separate object when present', function() {
|
|
@@ -469,6 +469,11 @@ describe('LiveIntentId', function() {
|
|
|
469
469
|
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'tdid': 'bar'}, 'tdid': {'id': 'bar', 'ext': {'rtiPartner': 'TDID', 'provider': provider}}});
|
|
470
470
|
});
|
|
471
471
|
|
|
472
|
+
it('should decode the segments as part of lipb', function() {
|
|
473
|
+
const result = liveIntentIdSubmodule.decode({ nonId: 'foo', 'segments': ['bar'] }, { params: defaultConfigParams });
|
|
474
|
+
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'segments': ['bar']}});
|
|
475
|
+
});
|
|
476
|
+
|
|
472
477
|
it('should allow disabling nonId resolution', function() {
|
|
473
478
|
let callBackSpy = sinon.spy();
|
|
474
479
|
let submoduleCallback = liveIntentIdSubmodule.getId({ params: {
|
|
@@ -536,6 +541,11 @@ describe('LiveIntentId', function() {
|
|
|
536
541
|
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'sonobi': 'bar'}, 'sonobi': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
537
542
|
});
|
|
538
543
|
|
|
544
|
+
it('should decode a triplelift id to a separate object when present', function() {
|
|
545
|
+
const result = liveIntentIdSubmodule.decode({ nonId: 'foo', triplelift: 'bar' }, defaultConfigParams);
|
|
546
|
+
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'triplelift': 'bar'}, 'triplelift': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
547
|
+
});
|
|
548
|
+
|
|
539
549
|
it('should decode a vidazoo id to a separate object when present', function() {
|
|
540
550
|
const result = liveIntentIdSubmodule.decode({ nonId: 'foo', vidazoo: 'bar' }, { params: defaultConfigParams });
|
|
541
551
|
expect(result).to.eql({'lipb': {'lipbid': 'foo', 'nonId': 'foo', 'vidazoo': 'bar'}, 'vidazoo': {'id': 'bar', 'ext': {'provider': 'liveintent.com'}}});
|
|
@@ -882,6 +892,39 @@ describe('LiveIntentId', function() {
|
|
|
882
892
|
});
|
|
883
893
|
});
|
|
884
894
|
|
|
895
|
+
it('triplelift', function () {
|
|
896
|
+
const userId = {
|
|
897
|
+
triplelift: { 'id': 'sample_id' }
|
|
898
|
+
};
|
|
899
|
+
const newEids = createEidsArray(userId);
|
|
900
|
+
expect(newEids.length).to.equal(1);
|
|
901
|
+
expect(newEids[0]).to.deep.equal({
|
|
902
|
+
source: 'liveintent.triplelift.com',
|
|
903
|
+
uids: [{
|
|
904
|
+
id: 'sample_id',
|
|
905
|
+
atype: 3
|
|
906
|
+
}]
|
|
907
|
+
});
|
|
908
|
+
});
|
|
909
|
+
|
|
910
|
+
it('triplelift with ext', function () {
|
|
911
|
+
const userId = {
|
|
912
|
+
triplelift: { 'id': 'sample_id', 'ext': { 'provider': 'some.provider.com' } }
|
|
913
|
+
};
|
|
914
|
+
const newEids = createEidsArray(userId);
|
|
915
|
+
expect(newEids.length).to.equal(1);
|
|
916
|
+
expect(newEids[0]).to.deep.equal({
|
|
917
|
+
source: 'liveintent.triplelift.com',
|
|
918
|
+
uids: [{
|
|
919
|
+
id: 'sample_id',
|
|
920
|
+
atype: 3,
|
|
921
|
+
ext: {
|
|
922
|
+
provider: 'some.provider.com'
|
|
923
|
+
}
|
|
924
|
+
}]
|
|
925
|
+
});
|
|
926
|
+
});
|
|
927
|
+
|
|
885
928
|
it('vidazoo', function () {
|
|
886
929
|
const userId = {
|
|
887
930
|
vidazoo: { 'id': 'sample_id' }
|