Skip to content

Commit

Permalink
UOE-11149: Fix Tests-Send Encoded SSPBurl in bid.Burl (#909)
Browse files Browse the repository at this point in the history
  • Loading branch information
pm-saurabh-narkhede authored and pm-viral-vala committed Sep 26, 2024
1 parent c91f041 commit 37a9c35
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion modules/pubmatic/openwrap/tracker/native_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ func Test_injectNativeCreativeTrackers(t *testing.T) {
},
endpoint: models.EndpointAppLovinMax,
},
wantBurl: `t.pubmatic.com/track?tid=1234&owsspburl=http://burl.com`,
wantBurl: `t.pubmatic.com/track?tid=1234&owsspburl=http%3A%2F%2Fburl.com`,
wantAdm: `<div style="position:absolute;left:0px;top:0px;visibility:hidden;"><img src="sample.com"></div>`,
wantErr: false,
},
Expand Down
14 changes: 7 additions & 7 deletions modules/pubmatic/openwrap/tracker/video_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,7 @@ func TestInjectVideoCreativeTrackers(t *testing.T) {
Endpoint: models.EndpointAppLovinMax,
},
},
wantBurl: "Tracking URL&owsspburl=https://burl.com",
wantBurl: "Tracking URL&owsspburl=https%3A%2F%2Fburl.com",
wantAdm: `<VAST><Ad><InLine><Error><![CDATA[Error URL]]></Error><Extensions><Extension><Pricing model="CPM" currency="USD"><![CDATA[1.2]]></Pricing></Extension></Extensions></InLine></Ad></VAST>`,
wantErr: false,
},
Expand All @@ -334,7 +334,7 @@ func TestInjectVideoCreativeTrackers(t *testing.T) {
Endpoint: models.EndpointAppLovinMax,
},
},
wantBurl: "Tracker URL&owsspburl=https://burl.com",
wantBurl: "Tracker URL&owsspburl=https%3A%2F%2Fburl.com",
wantAdm: `<VAST version="3.0"><Ad><InLine><Error><![CDATA[Error URL]]></Error><Pricing model="CPM" currency="USD"><![CDATA[1.2]]></Pricing></InLine></Ad></VAST>`,
wantErr: false,
},
Expand All @@ -357,7 +357,7 @@ func TestInjectVideoCreativeTrackers(t *testing.T) {
Endpoint: models.EndpointAppLovinMax,
},
},
wantBurl: "Tracker URL&owsspburl=https://burl.com",
wantBurl: "Tracker URL&owsspburl=https%3A%2F%2Fburl.com",
wantAdm: `<VAST version="3.0"><Ad id="601364"><InLine><AdSystem><![CDATA[Acudeo Compatible]]></AdSystem><AdTitle><![CDATA[VAST 2.0 Instream Test 1]]></AdTitle><Description><![CDATA[VAST 2.0 Instream Test 1]]></Description><Impression><![CDATA[http://172.16.4.213/AdServer/AdDisplayTrackerServlet?operId=1&pubId=5890&siteId=47163&adId=1405268&adType=13&adServerId=243&kefact=70.000000&kaxefact=70.000000&kadNetFrequecy=0&kadwidth=0&kadheight=0&kadsizeid=97&kltstamp=1529929473&indirectAdId=0&adServerOptimizerId=2&ranreq=0.1&kpbmtpfact=100.000000&dcId=1&tldId=0&passback=0&svr=MADS1107&ekefact=Ad8wW91TCwCmdG0jlfjXn7Tyzh20hnTVx-m5DoNSep-RXGDr&ekaxefact=Ad8wWwRUCwAGir4Zzl1eF0bKiC-qrCV0D0yp_eE7YizB_BQk&ekpbmtpfact=Ad8wWxRUCwD7qgzwwPE2LnS5-Ou19uO5amJl1YT6-XVFvQ41&imprId=48F73E1A-7F23-443D-A53C-30EE6BBF5F7F&oid=48F73E1A-7F23-443D-A53C-30EE6BBF5F7F&crID=creative-1_1_2&ucrid=160175026529250297&campaignId=17050&creativeId=0&pctr=0.000000&wDSPByrId=511&wDspId=6&wbId=0&wrId=0&wAdvID=3170&isRTB=1&rtbId=EBCA079F-8D7C-45B8-B733-92951F670AA1&pmZoneId=zone1&pageURL=www.yahoo.com&lpu=ae.com]]></Impression><Impression><![CDATA[https://dsptracker.com/{PSPM}]]></Impression><Error><![CDATA[Error URL]]></Error><Error><![CDATA[http://172.16.4.213/track?operId=7&p=5890&s=47163&a=1405268&wa=243&ts=1529929473&wc=17050&crId=creative-1_1_2&ucrid=160175026529250297&impid=48F73E1A-7F23-443D-A53C-30EE6BBF5F7F&advertiser_id=3170&ecpm=70.000000&er=[ERRORCODE]]]></Error><Error><![CDATA[https://Errortrack.com?p=1234&er=[ERRORCODE]]]></Error><Creatives><Creative AdID="601364"><Linear skipoffset="20%"><Duration><![CDATA[00:00:04]]></Duration><VideoClicks><ClickTracking><![CDATA[http://172.16.4.213/track?operId=7&p=5890&s=47163&a=1405268&wa=243&ts=1529929473&wc=17050&crId=creative-1_1_2&ucrid=160175026529250297&impid=48F73E1A-7F23-443D-A53C-30EE6BBF5F7F&advertiser_id=3170&ecpm=70.000000&e=99]]></ClickTracking><ClickThrough><![CDATA[https://www.sample.com]]></ClickThrough></VideoClicks><MediaFiles><MediaFile delivery="progressive" type="video/mp4" bitrate="500" width="400" height="300" scalable="true" maintainAspectRatio="true"><![CDATA[https://stagingnyc.pubmatic.com:8443/video/Shashank/mediaFileHost/media/mp4-sample-1.mp4]]></MediaFile><MediaFile delivery="progressive" type="video/mp4" bitrate="500" width="400" height="300" scalable="true" maintainAspectRatio="true"><![CDATA[https://stagingnyc.pubmatic.com:8443/video/Shashank/mediaFileHost/media/mp4-sample-2.mp4]]></MediaFile></MediaFiles></Linear></Creative></Creatives><Pricing model="CPM" currency="USD"><![CDATA[1.2]]></Pricing></InLine></Ad></VAST>`,
wantErr: false,
},
Expand All @@ -380,7 +380,7 @@ func TestInjectVideoCreativeTrackers(t *testing.T) {
Endpoint: models.EndpointAppLovinMax,
},
},
wantBurl: "Tracker URL&owsspburl=https://burl.com",
wantBurl: "Tracker URL&owsspburl=https%3A%2F%2Fburl.com",
wantAdm: `<VAST version="2.0"><Ad id="123"><Wrapper><AdSystem><![CDATA[DSP]]></AdSystem><VASTAdTagURI><![CDATA[https://stagingnyc.pubmatic.com:8443/test/pub_vast.xml]]></VASTAdTagURI><Error><![CDATA[Error URL]]></Error><Error><![CDATA[https://track.dsp.com/er=[ERRORCODE]/tracker/error]]></Error><Impression><![CDATA[https://track.dsp.com?e=impression]]></Impression><Creatives><Creative><Linear><TrackingEvents/><VideoClicks><ClickTracking><![CDATA[http://track.dsp.com/tracker/click]]></ClickTracking></VideoClicks></Linear></Creative></Creatives><Extensions><Extension><Pricing model="CPM" currency="USD"><![CDATA[1.2]]></Pricing></Extension></Extensions></Wrapper></Ad></VAST>`,
wantErr: false,
},
Expand All @@ -403,7 +403,7 @@ func TestInjectVideoCreativeTrackers(t *testing.T) {
Endpoint: models.EndpointAppLovinMax,
},
},
wantBurl: "Tracker URL&owsspburl=https://burl.com",
wantBurl: "Tracker URL&owsspburl=https%3A%2F%2Fburl.com",
wantAdm: `<VAST version="3.0"><Ad id="601364"><InLine><AdSystem><![CDATA[Acudeo Compatible]]></AdSystem><AdTitle><![CDATA[VAST 2.0 Instream Test 1]]></AdTitle><Description><![CDATA[VAST 2.0 Instream Test 1]]></Description><Impression><![CDATA[http://172.16.4.213/AdServer/AdDisplayTrackerServlet]]></Impression><Impression><![CDATA[https://dsptracker.com/{PSPM}]]></Impression><Error><![CDATA[Error URL]]></Error><Error><![CDATA[http://172.16.4.213/track]]></Error><Error><![CDATA[https://Errortrack.com]]></Error><Creatives><Creative AdID="601364"><Linear skipoffset="20%"><Duration><![CDATA[00:00:04]]></Duration><VideoClicks><ClickTracking><![CDATA[http://172.16.4.213/track]]></ClickTracking><ClickThrough><![CDATA[https://www.sample.com]]></ClickThrough></VideoClicks><MediaFiles><MediaFile delivery="progressive" type="video/mp4" bitrate="500" width="400" height="300" scalable="true" maintainAspectRatio="true"><![CDATA[https://stagingnyc.pubmatic.com:8443/video/Shashank/mediaFileHost/media/mp4-sample-1.mp4]]]></MediaFile><MediaFile delivery="progressive" type="video/mp4" bitrate="500" width="400" height="300" scalable="true" maintainAspectRatio="true"><![CDATA[https://stagingnyc.pubmatic.com:8443/video/Shashank/mediaFileHost/media/mp4-sample-2.mp4]]]></MediaFile></MediaFiles></Linear></Creative></Creatives><Pricing model="CPM" currency="USD"><![CDATA[1.2]]></Pricing></InLine></Ad></VAST>`,
wantErr: false,
},
Expand All @@ -426,7 +426,7 @@ func TestInjectVideoCreativeTrackers(t *testing.T) {
Endpoint: models.EndpointAppLovinMax,
},
},
wantBurl: "Tracker URL&owsspburl=https://burl.com",
wantBurl: "Tracker URL&owsspburl=https%3A%2F%2Fburl.com",
wantAdm: `<VAST version="2.0"><Ad id="123"><Wrapper><AdSystem><![CDATA[DSP]]></AdSystem><VASTAdTagURI><![CDATA[https://stagingnyc.pubmatic.com:8443/test/pub_vast.xml]]></VASTAdTagURI><Error><![CDATA[Error URL]]></Error><Error><![CDATA[https://track.dsp.com/er=[ERRORCODE]/tracker/error]]></Error><Impression><![CDATA[https://track.dsp.com?e=impression]]></Impression><Creatives><Creative><Linear><TrackingEvents/><VideoClicks><ClickTracking><![CDATA[http://track.dsp.com/tracker/click]]></ClickTracking></VideoClicks></Linear></Creative></Creatives><Extensions><Extension><Pricing model="CPM" currency="USD"><![CDATA[1.2]]></Pricing></Extension></Extensions></Wrapper></Ad></VAST>`,
wantErr: false,
},
Expand All @@ -448,7 +448,7 @@ func TestInjectVideoCreativeTrackers(t *testing.T) {
Endpoint: models.EndpointAppLovinMax,
},
},
wantBurl: "Tracker URL&owsspburl=https://burl.com",
wantBurl: "Tracker URL&owsspburl=https%3A%2F%2Fburl.com",
wantAdm: `<VAST version="3.0"> <Ad id="601364"><InLine><AdSystem><![CDATA[Acudeo Compatible]]></AdSystem><AdTitle><![CDATA[VAST 2.0 Instream Test 1]]></AdTitle><Description><![CDATA[VAST 2.0 Instream Test 1]]></Description><Impression><![CDATA[https://t.pubmatic.com/wt?pubid=156021&purl=https%3A%2F%2Fwww.financialexpress.com%2F&tst=1533048550&iid=9fc7e570-9b01-4cfb-8381-0dc1eec16d27-dieuf&bidid=36110151cad7636&pid=116&pdvid=24&slot=div-gpt-ad-1478842567868-0&pn=rubicon&en=0.02&eg=0.02&kgpv=300x250%40300x250]]></Impression><Impression><![CDATA[http://172.16.4.213/AdServer/AdDisplayTrackerServlet]]></Impression><Impression><![CDATA[https://dsptracker.com/{PSPM}]]></Impression><Error><![CDATA[Error URL]]></Error><Error><![CDATA[http://172.16.4.213/track]]></Error><Error><![CDATA[https://Errortrack.com]]></Error><Creatives><Creative AdID="601364"><Linear skipoffset="20%"><Duration><![CDATA[00:00:04]]></Duration><VideoClicks><ClickTracking><![CDATA[http://172.16.4.213/track]]></ClickTracking><ClickThrough><![CDATA[https://www.sample.com]]></ClickThrough></VideoClicks><MediaFiles><MediaFile delivery="progressive" type="video/mp4" bitrate="500" width="400" height="300" scalable="true" maintainAspectRatio="true"><![CDATA[https://stagingnyc.pubmatic.com:8443/video/Shashank/mediaFileHost/media/mp4-sample-1.mp4]]]></MediaFile><MediaFile delivery="progressive" type="video/mp4" bitrate="500" width="400" height="300" scalable="true" maintainAspectRatio="true"><![CDATA[https://stagingnyc.pubmatic.com:8443/video/Shashank/mediaFileHost/media/mp4-sample-2.mp4]]]></MediaFile></MediaFiles></Linear></Creative></Creatives></InLine></Ad></VAST>`,
wantErr: false,
},
Expand Down

0 comments on commit 37a9c35

Please sign in to comment.