prebid.js 9.46.0 → 9.48.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.
Files changed (325) hide show
  1. package/.github/codeql/queries/jsonRequestContentType.ql +18 -0
  2. package/AGENTS.md +42 -0
  3. package/CLAUDE.md +1 -0
  4. package/babelConfig.js +1 -1
  5. package/dist/33acrossAnalyticsAdapter.js +1 -1
  6. package/dist/33acrossBidAdapter.js +1 -1
  7. package/dist/33acrossIdSystem.js +1 -1
  8. package/dist/BTBidAdapter.js +1 -1
  9. package/dist/adagioAnalyticsAdapter.js +1 -1
  10. package/dist/adagioBidAdapter.js +1 -1
  11. package/dist/adagioUtils.js +1 -1
  12. package/dist/addefendBidAdapter.js +1 -1
  13. package/dist/adgenerationBidAdapter.js +1 -1
  14. package/dist/adlooxRtdProvider.js +1 -1
  15. package/dist/adqueryBidAdapter.js +1 -1
  16. package/dist/adrelevantisBidAdapter.js +1 -1
  17. package/dist/adstirBidAdapter.js +1 -1
  18. package/dist/adtrgtmeBidAdapter.js +1 -1
  19. package/dist/advangUtils.js +1 -1
  20. package/dist/adverxoBidAdapter.js +1 -1
  21. package/dist/adxcgAnalyticsAdapter.js +1 -1
  22. package/dist/adxcgBidAdapter.js +1 -1
  23. package/dist/adyoulikeBidAdapter.js +1 -1
  24. package/dist/agmaAnalyticsAdapter.js +1 -1
  25. package/dist/ajaBidAdapter.js +1 -1
  26. package/dist/amxBidAdapter.js +1 -1
  27. package/dist/amxIdSystem.js +1 -1
  28. package/dist/aniviewBidAdapter.js +1 -1
  29. package/dist/appierAnalyticsAdapter.js +1 -1
  30. package/dist/appnexusBidAdapter.js +1 -1
  31. package/dist/asoBidAdapter.js +1 -1
  32. package/dist/axonixBidAdapter.js +1 -1
  33. package/dist/beopBidAdapter.js +1 -1
  34. package/dist/bidglassBidAdapter.js +1 -1
  35. package/dist/big-richmediaBidAdapter.js +1 -1
  36. package/dist/bitmediaBidAdapter.js +1 -1
  37. package/dist/blueBidAdapter.js +1 -1
  38. package/dist/blueUtils.js +1 -0
  39. package/dist/bmsBidAdapter.js +1 -1
  40. package/dist/bridBidAdapter.js +1 -1
  41. package/dist/bridgeuppBidAdapter.js +1 -1
  42. package/dist/bridgewellBidAdapter.js +1 -1
  43. package/dist/brightMountainMediaBidAdapter.js +1 -1
  44. package/dist/browsiUtils.js +1 -1
  45. package/dist/carodaBidAdapter.js +1 -1
  46. package/dist/chtnwBidAdapter.js +1 -1
  47. package/dist/chunk-core.js +1 -1
  48. package/dist/concertBidAdapter.js +1 -1
  49. package/dist/connectadBidAdapter.js +1 -1
  50. package/dist/consumableBidAdapter.js +1 -1
  51. package/dist/contxtfulBidAdapter.js +1 -1
  52. package/dist/conversantAnalyticsAdapter.js +1 -1
  53. package/dist/conversantBidAdapter.js +1 -1
  54. package/dist/craftBidAdapter.js +1 -1
  55. package/dist/criteoBidAdapter.js +1 -1
  56. package/dist/cwireBidAdapter.js +1 -1
  57. package/dist/czechAdIdSystem.js +1 -1
  58. package/dist/dailymotionBidAdapter.js +1 -1
  59. package/dist/debugging-standalone.js +1 -1
  60. package/dist/dependencies.json +16 -2
  61. package/dist/dspxBidAdapter.js +1 -1
  62. package/dist/dxkultureBidAdapter.js +1 -1
  63. package/dist/dynamicAdBoostRtdProvider.js +1 -1
  64. package/dist/eplanningBidAdapter.js +1 -1
  65. package/dist/eskimiBidAdapter.js +1 -1
  66. package/dist/euidIdSystem.js +1 -1
  67. package/dist/exadsBidAdapter.js +1 -1
  68. package/dist/excoBidAdapter.js +1 -1
  69. package/dist/feedadBidAdapter.js +1 -1
  70. package/dist/finativeBidAdapter.js +1 -1
  71. package/dist/freewheel-sspBidAdapter.js +1 -1
  72. package/dist/gmosspBidAdapter.js +1 -1
  73. package/dist/gptUtils.js +1 -1
  74. package/dist/greenbidsAnalyticsAdapter.js +1 -1
  75. package/dist/greenbidsBidAdapter.js +1 -1
  76. package/dist/greenbidsRtdProvider.js +1 -1
  77. package/dist/gridBidAdapter.js +1 -1
  78. package/dist/gumgumBidAdapter.js +1 -1
  79. package/dist/h12mediaBidAdapter.js +1 -1
  80. package/dist/hypelabBidAdapter.js +1 -1
  81. package/dist/id5AnalyticsAdapter.js +1 -1
  82. package/dist/id5IdSystem.js +1 -1
  83. package/dist/imdsBidAdapter.js +1 -1
  84. package/dist/improvedigitalBidAdapter.js +1 -1
  85. package/dist/inmobiBidAdapter.js +1 -1
  86. package/dist/insticatorBidAdapter.js +1 -1
  87. package/dist/intentIqAnalyticsAdapter.js +1 -1
  88. package/dist/ixBidAdapter.js +1 -1
  89. package/dist/jixieBidAdapter.js +1 -1
  90. package/dist/justpremiumBidAdapter.js +1 -1
  91. package/dist/kargoBidAdapter.js +1 -1
  92. package/dist/kimberliteBidAdapter.js +1 -1
  93. package/dist/konduitAnalyticsAdapter.js +1 -1
  94. package/dist/kueezBidAdapter.js +1 -1
  95. package/dist/lassoBidAdapter.js +1 -1
  96. package/dist/lifestreetBidAdapter.js +1 -1
  97. package/dist/liveIntentId.js +1 -1
  98. package/dist/logicadBidAdapter.js +1 -1
  99. package/dist/loglyliftBidAdapter.js +1 -1
  100. package/dist/luceadBidAdapter.js +1 -1
  101. package/dist/luponmediaBidAdapter.js +1 -1
  102. package/dist/mabidderBidAdapter.js +1 -1
  103. package/dist/madsenseBidAdapter.js +1 -1
  104. package/dist/magniteAnalyticsAdapter.js +1 -1
  105. package/dist/malltvAnalyticsAdapter.js +1 -1
  106. package/dist/marsmediaBidAdapter.js +1 -1
  107. package/dist/mediafuseBidAdapter.js +1 -1
  108. package/dist/medianetBidAdapter.js +1 -1
  109. package/dist/medianetUtils.js +1 -1
  110. package/dist/mediasquareBidAdapter.js +1 -1
  111. package/dist/mgidBidAdapter.js +1 -1
  112. package/dist/missenaBidAdapter.js +1 -1
  113. package/dist/mobilefuseBidAdapter.js +1 -1
  114. package/dist/nativeryBidAdapter.js +1 -0
  115. package/dist/nextMillenniumBidAdapter.js +1 -1
  116. package/dist/nexx360Utils.js +1 -1
  117. package/dist/nobidAnalyticsAdapter.js +1 -1
  118. package/dist/nobidBidAdapter.js +1 -1
  119. package/dist/nodalsAiRtdProvider.js +1 -1
  120. package/dist/not-for-prod/prebid.js +187 -184
  121. package/dist/oguryBidAdapter.js +1 -1
  122. package/dist/onetagBidAdapter.js +1 -1
  123. package/dist/ooloAnalyticsAdapter.js +1 -1
  124. package/dist/openxBidAdapter.js +1 -1
  125. package/dist/optidigitalBidAdapter.js +1 -1
  126. package/dist/orbidderBidAdapter.js +1 -1
  127. package/dist/outbrainBidAdapter.js +1 -1
  128. package/dist/pinkLionBidAdapter.js +1 -0
  129. package/dist/pixfutureBidAdapter.js +1 -1
  130. package/dist/prebidServerBidAdapter.js +1 -1
  131. package/dist/priceFloors.js +1 -1
  132. package/dist/publinkIdSystem.js +1 -1
  133. package/dist/pubmaticAnalyticsAdapter.js +1 -1
  134. package/dist/pubmaticBidAdapter.js +1 -1
  135. package/dist/pubmaticRtdProvider.js +1 -1
  136. package/dist/pubwiseAnalyticsAdapter.js +1 -1
  137. package/dist/pubxaiAnalyticsAdapter.js +1 -1
  138. package/dist/pubxaiRtdProvider.js +1 -1
  139. package/dist/pxyzBidAdapter.js +1 -1
  140. package/dist/quantcastBidAdapter.js +1 -1
  141. package/dist/readpeakBidAdapter.js +1 -1
  142. package/dist/relaidoBidAdapter.js +1 -1
  143. package/dist/retailspotBidAdapter.js +1 -1
  144. package/dist/rhythmoneBidAdapter.js +1 -1
  145. package/dist/riseUtils.js +1 -1
  146. package/dist/rtbhouseBidAdapter.js +1 -1
  147. package/dist/rubiconBidAdapter.js +1 -1
  148. package/dist/seedingAllianceBidAdapter.js +1 -1
  149. package/dist/seedtagBidAdapter.js +1 -1
  150. package/dist/sharethroughAnalyticsAdapter.js +1 -1
  151. package/dist/sharethroughBidAdapter.js +1 -1
  152. package/dist/showheroes-bsBidAdapter.js +1 -1
  153. package/dist/smaatoBidAdapter.js +1 -1
  154. package/dist/smartadserverBidAdapter.js +1 -1
  155. package/dist/smartxBidAdapter.js +1 -1
  156. package/dist/smilewantedBidAdapter.js +1 -1
  157. package/dist/snigelBidAdapter.js +1 -1
  158. package/dist/sonobiBidAdapter.js +1 -1
  159. package/dist/sovrnBidAdapter.js +1 -1
  160. package/dist/sparteoBidAdapter.js +1 -1
  161. package/dist/sspBCBidAdapter.js +1 -1
  162. package/dist/stroeerCoreBidAdapter.js +1 -1
  163. package/dist/stvBidAdapter.js +1 -1
  164. package/dist/sublimeBidAdapter.js +1 -1
  165. package/dist/taboolaBidAdapter.js +1 -1
  166. package/dist/tappxBidAdapter.js +1 -1
  167. package/dist/targetVideoBidAdapter.js +1 -1
  168. package/dist/teadsBidAdapter.js +1 -1
  169. package/dist/terceptAnalyticsAdapter.js +1 -1
  170. package/dist/themoneytizerBidAdapter.js +1 -1
  171. package/dist/trionBidAdapter.js +1 -1
  172. package/dist/tripleliftBidAdapter.js +1 -1
  173. package/dist/ttdBidAdapter.js +1 -1
  174. package/dist/ucfunnelAnalyticsAdapter.js +1 -1
  175. package/dist/uid2IdSystem.js +1 -1
  176. package/dist/underdogmediaBidAdapter.js +1 -1
  177. package/dist/undertoneBidAdapter.js +1 -1
  178. package/dist/unifiedIdSystem.js +1 -1
  179. package/dist/unrulyBidAdapter.js +1 -1
  180. package/dist/userId.js +1 -1
  181. package/dist/vidazooUtils.js +1 -1
  182. package/dist/videobyteBidAdapter.js +1 -1
  183. package/dist/visxBidAdapter.js +1 -1
  184. package/dist/vuukleBidAdapter.js +1 -1
  185. package/dist/weboramaRtdProvider.js +1 -1
  186. package/dist/widespaceBidAdapter.js +1 -1
  187. package/dist/winrBidAdapter.js +1 -1
  188. package/dist/xeUtils.js +1 -1
  189. package/dist/yahooAdsBidAdapter.js +1 -1
  190. package/dist/yandexBidAdapter.js +1 -1
  191. package/dist/yieldmoBidAdapter.js +1 -1
  192. package/dist/yieldoneAnalyticsAdapter.js +1 -1
  193. package/eslint.config.js +1 -3
  194. package/gulpHelpers.js +3 -6
  195. package/gulpfile.js +25 -24
  196. package/karma.conf.maker.js +1 -3
  197. package/libraries/advangUtils/index.js +3 -4
  198. package/libraries/blueUtils/bidderUtils.js +113 -0
  199. package/libraries/browsiUtils/browsiUtils.js +1 -2
  200. package/libraries/gptUtils/gptUtils.js +1 -2
  201. package/libraries/liveIntentId/shared.js +4 -0
  202. package/libraries/xeUtils/bidderUtils.js +3 -4
  203. package/modules/adagioBidAdapter.js +1 -2
  204. package/modules/addefendBidAdapter.md +1 -1
  205. package/modules/adtrgtmeBidAdapter.js +6 -8
  206. package/modules/aduptechBidAdapter.md +1 -1
  207. package/modules/adverxoBidAdapter.js +3 -3
  208. package/modules/blueBidAdapter.js +24 -104
  209. package/modules/bmsBidAdapter.js +25 -105
  210. package/modules/concertBidAdapter.md +1 -1
  211. package/modules/contxtfulBidAdapter.js +56 -10
  212. package/modules/conversantBidAdapter.js +0 -58
  213. package/modules/cwireBidAdapter.js +8 -0
  214. package/modules/czechAdIdSystem.js +13 -3
  215. package/modules/dynamicAdBoostRtdProvider.js +16 -33
  216. package/modules/dynamicAdBoostRtdProvider.md +1 -6
  217. package/modules/ixBidAdapter.js +2 -3
  218. package/modules/luponmediaBidAdapter.js +117 -522
  219. package/modules/luponmediaBidAdapter.md +2 -3
  220. package/modules/mediasquareBidAdapter.js +14 -20
  221. package/modules/microadBidAdapter.js +0 -1
  222. package/modules/nativeryBidAdapter.js +135 -0
  223. package/modules/nativeryBidAdapter.md +95 -0
  224. package/modules/nativoBidAdapter.js +3 -3
  225. package/modules/onetagBidAdapter.js +0 -1
  226. package/modules/pinkLionBidAdapter.js +17 -0
  227. package/modules/pinkLionBidAdapter.md +79 -0
  228. package/modules/prebidServerBidAdapter/ortbConverter.js +1 -1
  229. package/modules/priceFloors.js +2 -2
  230. package/modules/pubmaticBidAdapter.js +4 -1
  231. package/modules/qortexRtdProvider.md +1 -1
  232. package/modules/reconciliationRtdProvider.md +4 -4
  233. package/modules/rtbhouseBidAdapter.js +4 -83
  234. package/modules/rubiconBidAdapter.js +1 -1
  235. package/modules/sspBCBidAdapter.js +1 -1
  236. package/modules/stroeerCoreBidAdapter.js +3 -3
  237. package/modules/stvBidAdapter.js +19 -14
  238. package/modules/topicsFpdModule.md +1 -1
  239. package/modules/unifiedIdSystem.js +8 -1
  240. package/modules/userId/eids.js +15 -0
  241. package/modules/videoModule/index.js +0 -1
  242. package/modules/videoModule/videoImpressionVerifier.js +0 -1
  243. package/modules/yieldlabBidAdapter.js +1 -2
  244. package/modules/yieldmoBidAdapter.js +1 -2
  245. package/package.json +13 -20
  246. package/src/Renderer.js +1 -2
  247. package/src/adapterManager.js +14 -4
  248. package/src/auction.js +2 -3
  249. package/src/config.js +1 -2
  250. package/src/cpmBucketManager.js +1 -2
  251. package/src/secureCreatives.js +2 -3
  252. package/src/targeting.js +1 -2
  253. package/test/fake-server/README.md +3 -3
  254. package/test/helpers/index_adapter_utils.js +2 -2
  255. package/test/helpers/testing-utils.js +1 -1
  256. package/test/spec/auctionmanager_spec.js +2 -3
  257. package/test/spec/fpd/enrichment_spec.js +1 -1
  258. package/test/spec/libraries/greedy/greedyPromise_spec.js +2 -2
  259. package/test/spec/modules/adfBidAdapter_spec.js +1 -1
  260. package/test/spec/modules/adnuntiusBidAdapter_spec.js +25 -9
  261. package/test/spec/modules/adtrgtmeBidAdapter_spec.js +2 -4
  262. package/test/spec/modules/adverxoBidAdapter_spec.js +25 -1
  263. package/test/spec/modules/afpBidAdapter_spec.js +0 -1
  264. package/test/spec/modules/bliinkBidAdapter_spec.js +15 -7
  265. package/test/spec/modules/contxtfulBidAdapter_spec.js +606 -82
  266. package/test/spec/modules/conversantBidAdapter_spec.js +1 -139
  267. package/test/spec/modules/cwireBidAdapter_spec.js +2 -2
  268. package/test/spec/modules/czechAdIdSystem_spec.js +4 -4
  269. package/test/spec/modules/displayioBidAdapter_spec.js +1 -1
  270. package/test/spec/modules/dynamicAdBoostRtdProvider_spec.js +0 -42
  271. package/test/spec/modules/enrichmentLiftMeasurement_spec.js +8 -8
  272. package/test/spec/modules/hypelabBidAdapter_spec.js +17 -11
  273. package/test/spec/modules/iasRtdProvider_spec.js +2 -2
  274. package/test/spec/modules/id5IdSystem_spec.js +1 -1
  275. package/test/spec/modules/idxIdSystem_spec.js +1 -2
  276. package/test/spec/modules/intentIqAnalyticsAdapter_spec.js +25 -25
  277. package/test/spec/modules/intentIqIdSystem_spec.js +32 -32
  278. package/test/spec/modules/kargoBidAdapter_spec.js +11 -5
  279. package/test/spec/modules/liveIntentIdSystem_spec.js +14 -0
  280. package/test/spec/modules/lmpIdSystem_spec.js +1 -2
  281. package/test/spec/modules/lockrAIMIdSystem_spec.js +2 -2
  282. package/test/spec/modules/luceadBidAdapter_spec.js +1 -1
  283. package/test/spec/modules/luponmediaBidAdapter_spec.js +186 -324
  284. package/test/spec/modules/mediaeyesBidAdapter_spec.js +1 -1
  285. package/test/spec/modules/mediakeysBidAdapter_spec.js +1 -2
  286. package/test/spec/modules/mediasquareBidAdapter_spec.js +13 -2
  287. package/test/spec/modules/missenaBidAdapter_spec.js +1 -1
  288. package/test/spec/modules/nativeryBidAdapter_spec.js +195 -0
  289. package/test/spec/modules/nexx360BidAdapter_spec.js +6 -6
  290. package/test/spec/modules/oguryBidAdapter_spec.js +2 -2
  291. package/test/spec/modules/omsBidAdapter_spec.js +1 -1
  292. package/test/spec/modules/onetagBidAdapter_spec.js +1 -2
  293. package/test/spec/modules/onomagicBidAdapter_spec.js +2 -2
  294. package/test/spec/modules/overtoneRtdProvider_spec.mjs +1 -1
  295. package/test/spec/modules/permutiveIdentityManagerIdSystem_spec.js +17 -14
  296. package/test/spec/modules/pinkLionBidAdapter_spec.js +480 -0
  297. package/test/spec/modules/prebidServerBidAdapter_spec.js +2 -2
  298. package/test/spec/modules/previousAuctionInfo_spec.js +2 -2
  299. package/test/spec/modules/pubmaticAnalyticsAdapter_spec.js +1 -1
  300. package/test/spec/modules/pubmaticBidAdapter_spec.js +19 -1
  301. package/test/spec/modules/pubmaticRtdProvider_spec.js +16 -17
  302. package/test/spec/modules/pubwiseAnalyticsAdapter_spec.js +2 -2
  303. package/test/spec/modules/rtbhouseBidAdapter_spec.js +0 -182
  304. package/test/spec/modules/rubiconBidAdapter_spec.js +3 -4
  305. package/test/spec/modules/sizeMappingV2_spec.js +1 -1
  306. package/test/spec/modules/sizeMapping_spec.js +2 -3
  307. package/test/spec/modules/stroeerCoreBidAdapter_spec.js +36 -26
  308. package/test/spec/modules/stvBidAdapter_spec.js +108 -40
  309. package/test/spec/modules/topLevelPaapi_spec.js +1 -1
  310. package/test/spec/modules/tpmnBidAdapter_spec.js +1 -1
  311. package/test/spec/modules/ttdBidAdapter_spec.js +1 -1
  312. package/test/spec/modules/unifiedIdSystem_spec.js +20 -0
  313. package/test/spec/modules/userId_spec.js +1 -1
  314. package/test/spec/modules/vibrantmediaBidAdapter_spec.js +1 -1
  315. package/test/spec/modules/videoModule/submodules/videojsVideoProvider_spec.js +1 -1
  316. package/test/spec/modules/yieldmoBidAdapter_spec.js +2 -2
  317. package/test/spec/modules/zeotapIdPlusIdSystem_spec.js +1 -2
  318. package/test/spec/unit/core/adapterManager_spec.js +29 -17
  319. package/test/spec/unit/core/targeting_spec.js +1 -1
  320. package/test/spec/unit/pbjs_api_spec.js +4 -5
  321. package/test/spec/utils_spec.js +20 -12
  322. package/test/test_deps.js +1 -1
  323. package/nightwatch.browserstack.json +0 -46
  324. package/nightwatch.conf.js +0 -36
  325. package/nightwatch.json +0 -40
@@ -193,9 +193,9 @@ describe('IntentIQ tests', function () {
193
193
  }
194
194
  });
195
195
  const currentBrowserLowerCase = detectBrowser();
196
-
196
+
197
197
  if (currentBrowserLowerCase === usedBrowser) {
198
- const at20request = server.requests[0];
198
+ const at20request = server.requests[0];
199
199
  expect(at20request.url).to.contain(`&source=${PREBID}`);
200
200
  expect(at20request.url).to.contain(`at=20`);
201
201
  }
@@ -205,10 +205,10 @@ describe('IntentIQ tests', function () {
205
205
  it('should send at=39 request and send source in it', function () {
206
206
  const callBackSpy = sinon.spy();
207
207
  const submoduleCallback = intentIqIdSubmodule.getId(defaultConfigParams).callback;
208
-
208
+
209
209
  submoduleCallback(callBackSpy);
210
210
  const request = server.requests[0];
211
-
211
+
212
212
  expect(request.url).to.contain(`&source=${PREBID}`);
213
213
  });
214
214
 
@@ -436,7 +436,7 @@ describe('IntentIQ tests', function () {
436
436
  browserBlackList: 'chrome'
437
437
  }
438
438
  });
439
-
439
+
440
440
  const at20request = server.requests[0];
441
441
  expect(at20request.url).to.contain(`&spd=${encodedSpd}`);
442
442
  expect(at20request.url).to.contain(`at=20`);
@@ -452,12 +452,12 @@ describe('IntentIQ tests', function () {
452
452
  browserBlackList: 'chrome'
453
453
  }
454
454
  });
455
-
456
- const at20request = server.requests[0];
455
+
456
+ const at20request = server.requests[0];
457
457
  expect(at20request.url).to.contain(`&spd=${encodedSpd}`);
458
458
  expect(at20request.url).to.contain(`at=20`);
459
459
  });
460
-
460
+
461
461
  it('should send spd from firstPartyData in localStorage in at=39 request', function () {
462
462
  const spdValue = { foo: 'bar', value: 42 };
463
463
  const encodedSpd = encodeURIComponent(JSON.stringify(spdValue));
@@ -466,10 +466,10 @@ describe('IntentIQ tests', function () {
466
466
 
467
467
  const callBackSpy = sinon.spy();
468
468
  const submoduleCallback = intentIqIdSubmodule.getId(defaultConfigParams).callback;
469
-
469
+
470
470
  submoduleCallback(callBackSpy);
471
471
  const request = server.requests[0];
472
-
472
+
473
473
  expect(request.url).to.contain(`&spd=${encodedSpd}`);
474
474
  expect(request.url).to.contain(`at=39`);
475
475
  });
@@ -481,7 +481,7 @@ describe('IntentIQ tests', function () {
481
481
 
482
482
  const callBackSpy = sinon.spy();
483
483
  const submoduleCallback = intentIqIdSubmodule.getId(defaultConfigParams).callback;
484
-
484
+
485
485
  submoduleCallback(callBackSpy);
486
486
  const request = server.requests[0];
487
487
 
@@ -493,19 +493,19 @@ describe('IntentIQ tests', function () {
493
493
  const spdValue = { foo: 'bar', value: 42 };
494
494
  let callBackSpy = sinon.spy();
495
495
  const submoduleCallback = intentIqIdSubmodule.getId(defaultConfigParams).callback;
496
-
496
+
497
497
  submoduleCallback(callBackSpy);
498
498
  const request = server.requests[0];
499
-
499
+
500
500
  request.respond(
501
501
  200,
502
502
  responseHeader,
503
503
  JSON.stringify({ pid: 'test_pid', data: 'test_personid', ls: true, spd: spdValue })
504
504
  );
505
-
505
+
506
506
  const storedLs = readData(FIRST_PARTY_KEY, ['html5', 'cookie'], storage);
507
507
  const parsedLs = JSON.parse(storedLs);
508
-
508
+
509
509
  expect(storedLs).to.not.be.null;
510
510
  expect(callBackSpy.calledOnce).to.be.true;
511
511
  expect(parsedLs).to.have.property('spd');
@@ -576,7 +576,7 @@ describe('IntentIQ tests', function () {
576
576
  gdprString: null,
577
577
  gppString: null,
578
578
  uspString: null
579
- };
579
+ };
580
580
 
581
581
  storeData(FIRST_PARTY_KEY, JSON.stringify(FPD), allowedStorage, storage)
582
582
  const callBackSpy = sinon.spy()
@@ -597,7 +597,7 @@ describe('IntentIQ tests', function () {
597
597
  gdprString: null,
598
598
  gppString: null,
599
599
  uspString: null
600
- };
600
+ };
601
601
 
602
602
  storeData(FIRST_PARTY_KEY, JSON.stringify(FPD), allowedStorage, storage)
603
603
  const returnedObject = intentIqIdSubmodule.getId({...allConfigParams, params: {...allConfigParams.params, partner: newPartnerId}});
@@ -1032,7 +1032,7 @@ describe('IntentIQ tests', function () {
1032
1032
 
1033
1033
  it('should store first party data under the silo key when siloEnabled is true', function () {
1034
1034
  const configParams = { params: {...allConfigParams.params, siloEnabled: true} };
1035
-
1035
+
1036
1036
  intentIqIdSubmodule.getId(configParams);
1037
1037
  const expectedKey = FIRST_PARTY_KEY + '_p_' + configParams.params.partner;
1038
1038
  const storedData = localStorage.getItem(expectedKey);
@@ -1121,10 +1121,10 @@ describe('IntentIQ tests', function () {
1121
1121
  }]
1122
1122
  }
1123
1123
  };
1124
-
1124
+
1125
1125
  intentIqIdSubmodule.getId(configParams);
1126
1126
  const syncRequest = server.requests[0];
1127
-
1127
+
1128
1128
  expect(syncRequest.url).to.include('general=Lee');
1129
1129
  });
1130
1130
  it('should send additionalParams in VR request', function () {
@@ -1143,10 +1143,10 @@ describe('IntentIQ tests', function () {
1143
1143
  let submoduleCallback = intentIqIdSubmodule.getId(configParams).callback;
1144
1144
  submoduleCallback(callBackSpy);
1145
1145
  const vrRequest = server.requests[0];
1146
-
1146
+
1147
1147
  expect(vrRequest.url).to.include('general=Lee');
1148
1148
  });
1149
-
1149
+
1150
1150
  it('should not send additionalParams in case it is not an array', function () {
1151
1151
  const configParams = {
1152
1152
  params: {
@@ -1163,10 +1163,10 @@ describe('IntentIQ tests', function () {
1163
1163
  let submoduleCallback = intentIqIdSubmodule.getId(configParams).callback;
1164
1164
  submoduleCallback(callBackSpy);
1165
1165
  const vrRequest = server.requests[0];
1166
-
1166
+
1167
1167
  expect(vrRequest.url).not.to.include('general=');
1168
1168
  });
1169
-
1169
+
1170
1170
  it('should not send additionalParams in case request url is too long', function () {
1171
1171
  const longValue = 'x'.repeat(5000000); // simulate long parameter
1172
1172
  const configParams = {
@@ -1184,7 +1184,7 @@ describe('IntentIQ tests', function () {
1184
1184
  let submoduleCallback = intentIqIdSubmodule.getId(configParams).callback;
1185
1185
  submoduleCallback(callBackSpy);
1186
1186
  const vrRequest = server.requests[0];
1187
-
1187
+
1188
1188
  expect(vrRequest.url).not.to.include('general=');
1189
1189
  });
1190
1190
 
@@ -1197,10 +1197,10 @@ describe('IntentIQ tests', function () {
1197
1197
  groupChanged: groupChangedSpy
1198
1198
  }
1199
1199
  };
1200
-
1200
+
1201
1201
  const submoduleCallback = intentIqIdSubmodule.getId(configParams).callback;
1202
1202
  submoduleCallback(callBackSpy);
1203
-
1203
+
1204
1204
  const request = server.requests[0];
1205
1205
  request.respond(
1206
1206
  200,
@@ -1211,7 +1211,7 @@ describe('IntentIQ tests', function () {
1211
1211
  data: { eids: [] }
1212
1212
  })
1213
1213
  );
1214
-
1214
+
1215
1215
  expect(callBackSpy.calledOnce).to.be.true;
1216
1216
  expect(groupChangedSpy.calledWith(WITHOUT_IIQ)).to.be.true;
1217
1217
  });
@@ -1225,10 +1225,10 @@ describe('IntentIQ tests', function () {
1225
1225
  groupChanged: groupChangedSpy
1226
1226
  }
1227
1227
  };
1228
-
1228
+
1229
1229
  const submoduleCallback = intentIqIdSubmodule.getId(configParams).callback;
1230
1230
  submoduleCallback(callBackSpy);
1231
-
1231
+
1232
1232
  const request = server.requests[0];
1233
1233
  request.respond(
1234
1234
  200,
@@ -1239,8 +1239,8 @@ describe('IntentIQ tests', function () {
1239
1239
  data: { eids: [] }
1240
1240
  })
1241
1241
  );
1242
-
1242
+
1243
1243
  expect(callBackSpy.calledOnce).to.be.true;
1244
1244
  expect(groupChangedSpy.calledWith(WITH_IIQ)).to.be.true;
1245
- });
1245
+ });
1246
1246
  });
@@ -1,7 +1,9 @@
1
1
  import { expect } from 'chai';
2
2
  import { spec } from 'modules/kargoBidAdapter.js';
3
3
  import { config } from 'src/config.js';
4
+ import { getStorageManager } from 'src/storageManager.js';
4
5
  const utils = require('src/utils');
6
+ const STORAGE = getStorageManager({bidderCode: 'kargo'});
5
7
 
6
8
  describe('kargo adapter tests', function() {
7
9
  let bid, outstreamBid, testBids, sandbox, clock, frozenNow = new Date(), oldBidderSettings;
@@ -1001,9 +1003,9 @@ describe('kargo adapter tests', function() {
1001
1003
  });
1002
1004
 
1003
1005
  it('retrieves CRB from cookies if localstorage is not functional', function() {
1004
- // Note: this does not cause localStorage to throw an error in Firefox so in that browser this
1005
- // test is not 100% true to its name
1006
- sandbox.stub(localStorage, 'getItem').throws();
1006
+ // Safari does not allow stubbing localStorage methods directly.
1007
+ // Stub the storage manager instead so all browsers behave consistently.
1008
+ sandbox.stub(STORAGE, 'getDataFromLocalStorage').throws();
1007
1009
  setCrb('valid', 'invalid');
1008
1010
 
1009
1011
  const payload = getPayloadFromTestBids(testBids, bidderRequest);
@@ -1269,7 +1271,9 @@ describe('kargo adapter tests', function() {
1269
1271
  });
1270
1272
 
1271
1273
  it('fails gracefully if there is no localStorage', function() {
1272
- sandbox.stub(localStorage, 'getItem').throws();
1274
+ sandbox.stub(STORAGE, 'getDataFromLocalStorage').throws();
1275
+ localStorage.removeItem('krg_crb');
1276
+ document.cookie = 'krg_crb=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/';
1273
1277
  let payload = getPayloadFromTestBids(testBids);
1274
1278
  expect(payload.user).to.deep.equal({
1275
1279
  crbIDs: {},
@@ -1589,7 +1593,9 @@ describe('kargo adapter tests', function() {
1589
1593
  });
1590
1594
 
1591
1595
  it('fails gracefully without localStorage', function() {
1592
- sandbox.stub(localStorage, 'getItem').throws();
1596
+ sandbox.stub(STORAGE, 'getDataFromLocalStorage').throws();
1597
+ localStorage.removeItem('krg_crb');
1598
+ document.cookie = 'krg_crb=; expires=Thu, 01 Jan 1970 00:00:00 GMT; path=/';
1593
1599
  let payload = getPayloadFromTestBids(testBids);
1594
1600
  expect(payload.page).to.be.undefined;
1595
1601
  });
@@ -1179,5 +1179,19 @@ describe('LiveIntentId', function() {
1179
1179
  }]
1180
1180
  });
1181
1181
  });
1182
+
1183
+ it('tdid sets matcher for liveintent', function() {
1184
+ const userId = {
1185
+ tdid: 'some-tdid'
1186
+ };
1187
+
1188
+ const newEids = createEidsArray(userId);
1189
+
1190
+ expect(newEids.length).to.equal(1);
1191
+ expect(newEids[0]).to.deep.include({
1192
+ source: 'adserver.org',
1193
+ matcher: 'liveintent.com'
1194
+ });
1195
+ });
1182
1196
  })
1183
1197
  })
@@ -1,5 +1,4 @@
1
1
  import { expect } from 'chai';
2
- import { find } from 'src/polyfill.js';
3
2
  import { config } from 'src/config.js';
4
3
  import {init, startAuctionHook, setSubmoduleRegistry, resetUserIds} from 'modules/userId/index.js';
5
4
  import { storage, lmpIdSubmodule } from 'modules/lmpIdSystem.js';
@@ -117,7 +116,7 @@ describe('LMPID System', () => {
117
116
  unit.bids.forEach(bid => {
118
117
  expect(bid).to.have.deep.nested.property('userId.lmpid');
119
118
  expect(bid.userId.lmpid).to.equal('stored-lmpid');
120
- const lmpidAsEid = find(bid.userIdAsEids, e => e.source == 'loblawmedia.ca');
119
+ const lmpidAsEid = bid.userIdAsEids.find(e => e.source == 'loblawmedia.ca');
121
120
  expect(lmpidAsEid).to.deep.equal({
122
121
  source: 'loblawmedia.ca',
123
122
  uids: [{
@@ -1,5 +1,5 @@
1
-
2
-
1
+
2
+
3
3
  import * as lockrAIMSystem from "../../../modules/lockrAIMIdSystem.js";
4
4
  import { hook } from "../../../src/hook.js";
5
5
  import { expect } from "chai";
@@ -1,4 +1,4 @@
1
-
1
+
2
2
  import { expect } from 'chai';
3
3
  import { spec } from 'modules/luceadBidAdapter.js';
4
4
  import sinon from 'sinon';