From 3f2218e0e36491df9d40d5b96b74d37cf45ab6c1 Mon Sep 17 00:00:00 2001 From: Maximiliano Zurita <76264143+maximilianozurita@users.noreply.github.com> Date: Fri, 17 Jan 2025 11:44:31 -0300 Subject: [PATCH] Revert "EPlanning Bid Adapter : adding support for schain (#12635)" This reverts commit 3fd206662560544cd3ff2d4d04184ba31cf3989a. --- modules/eplanningBidAdapter.js | 6 +- test/spec/modules/eplanningBidAdapter_spec.js | 75 +------------------ 2 files changed, 2 insertions(+), 79 deletions(-) diff --git a/modules/eplanningBidAdapter.js b/modules/eplanningBidAdapter.js index c163a69b502..1fe5cb09c10 100644 --- a/modules/eplanningBidAdapter.js +++ b/modules/eplanningBidAdapter.js @@ -4,7 +4,6 @@ import {registerBidder} from '../src/adapters/bidderFactory.js'; import {getStorageManager} from '../src/storageManager.js'; import {BANNER, VIDEO} from '../src/mediaTypes.js'; import {isSlotMatchingAdUnitCode} from '../libraries/gptUtils/gptUtils.js'; -import {serializeSupplyChain} from '../libraries/schainSerializer/schainSerializer.js'; const BIDDER_CODE = 'eplanning'; export const storage = getStorageManager({bidderCode: BIDDER_CODE}); @@ -40,7 +39,6 @@ export const spec = { const method = 'GET'; const dfpClientId = '1'; const sec = 'ROS'; - const schain = bidRequests[0].schain; let url; let params; const urlConfig = getUrlConfig(bidRequests); @@ -72,9 +70,7 @@ export const spec = { if (pcrs) { params.crs = pcrs; } - if (schain && schain.nodes.length > 2) { - params.sch = serializeSupplyChain(schain, ['asi', 'sid', 'hp', 'rid', 'name', 'domain']); - } + if (referrerUrl) { params.fr = cutUrl(referrerUrl); } diff --git a/test/spec/modules/eplanningBidAdapter_spec.js b/test/spec/modules/eplanningBidAdapter_spec.js index 60845c7354f..a381d7644a1 100644 --- a/test/spec/modules/eplanningBidAdapter_spec.js +++ b/test/spec/modules/eplanningBidAdapter_spec.js @@ -53,68 +53,6 @@ describe('E-Planning Adapter', function () { 'adUnitCode': ADUNIT_CODE2, 'sizes': [[300, 250], [300, 600]], }; - const validBidWithSchain = { - 'bidder': 'eplanning', - 'bidId': BID_ID2, - 'params': { - 'ci': CI, - }, - 'adUnitCode': ADUNIT_CODE2, - 'sizes': [[300, 250], [300, 600]], - 'schain': { - ver: '1.0', - complete: 1, - nodes: [ - { - asi: 'directseller.com', - sid: '00001', - rid: 'BidRequest1', - hp: 1, - name: 'publisher', - domain: 'publisher.com' - }, - { - asi: 'reseller.com', - sid: 'aaaaa', - rid: 'BidRequest2', - hp: 1, - name: 'publisher2', - domain: 'publisher2.com' - }, - { - asi: 'reseller3.com', - sid: 'aaaaab', - rid: 'BidRequest3', - hp: 1, - name: 'publisher3', - domain: 'publisher3.com' - } - ] - } - }; - const validBidWithSchainNodes = { - 'bidder': 'eplanning', - 'bidId': BID_ID2, - 'params': { - 'ci': CI, - }, - 'adUnitCode': ADUNIT_CODE2, - 'sizes': [[300, 250], [300, 600]], - 'schain': { - ver: '1.0', - complete: 1, - nodes: [ - { - asi: 'directseller.com', - sid: '00001', - rid: 'BidRequest1', - hp: 1, - name: 'publisher', - domain: 'publisher.com' - } - ] - } - }; const ML = '1'; const validBidMappingLinear = { 'bidder': 'eplanning', @@ -789,18 +727,7 @@ describe('E-Planning Adapter', function () { expect(data.vctx).to.equal(2); expect(data.vv).to.equal(3); }); - it('should return sch parameter', function () { - let bidRequests = [validBidWithSchain], schainExpected, schain; - schain = validBidWithSchain.schain; - schainExpected = schain.ver + ',' + schain.complete + '!' + schain.nodes.map(node => node.asi + ',' + node.sid + ',' + node.hp + ',' + node.rid + ',' + node.name + ',' + node.domain).join('!'); - const data = spec.buildRequests(bidRequests, bidderRequest).data; - expect(data.sch).to.deep.equal(schainExpected); - }); - it('should not return sch parameter', function () { - let bidRequests = [validBidWithSchainNodes]; - const data = spec.buildRequests(bidRequests, bidderRequest).data; - expect(data.sch).to.equal(undefined); - }); + it('should return correct e parameter with linear mapping attribute with more than one adunit', function () { let bidRequestsML = [validBidMappingLinear]; const NEW_CODE = ADUNIT_CODE + '2';