diff --git a/adapters/pubmatic/pubmatic.go b/adapters/pubmatic/pubmatic.go index bcff41d43f1..beb359afb96 100644 --- a/adapters/pubmatic/pubmatic.go +++ b/adapters/pubmatic/pubmatic.go @@ -65,7 +65,6 @@ type extRequestAdServer struct { Wrapper *pubmaticWrapperExt `json:"wrapper,omitempty"` Acat []string `json:"acat,omitempty"` Marketplace *marketplaceReqExt `json:"marketplace,omitempty"` - openrtb_ext.ExtRequest } type respExt struct { @@ -351,7 +350,6 @@ func extractPubmaticExtFromRequest(request *openrtb2.BidRequest) (extRequestAdSe if err != nil { return pmReqExt, fmt.Errorf("error decoding Request.ext : %s", err.Error()) } - pmReqExt.ExtRequest = *reqExt reqExtBidderParams := make(map[string]json.RawMessage) if reqExt.Prebid.BidderParams != nil { diff --git a/adapters/pubmatic/pubmatic_test.go b/adapters/pubmatic/pubmatic_test.go index 9c6af0cba40..90f405d61e2 100644 --- a/adapters/pubmatic/pubmatic_test.go +++ b/adapters/pubmatic/pubmatic_test.go @@ -197,14 +197,8 @@ func TestExtractPubmaticExtFromRequest(t *testing.T) { Ext: json.RawMessage(`{"prebid":{"bidderparams":{}}}`), }, }, - expectedReqExt: extRequestAdServer{ - ExtRequest: openrtb_ext.ExtRequest{ - Prebid: openrtb_ext.ExtRequestPrebid{ - BidderParams: json.RawMessage("{}"), - }, - }, - }, - wantErr: false, + expectedReqExt: extRequestAdServer{}, + wantErr: false, }, { name: "Only Pubmatic wrapper ext present", @@ -215,11 +209,6 @@ func TestExtractPubmaticExtFromRequest(t *testing.T) { }, expectedReqExt: extRequestAdServer{ Wrapper: &pubmaticWrapperExt{ProfileID: 123, VersionID: 456}, - ExtRequest: openrtb_ext.ExtRequest{ - Prebid: openrtb_ext.ExtRequestPrebid{ - BidderParams: json.RawMessage(`{"wrapper":{"profile":123,"version":456}}`), - }, - }, }, wantErr: false, }, @@ -242,11 +231,6 @@ func TestExtractPubmaticExtFromRequest(t *testing.T) { expectedReqExt: extRequestAdServer{ Wrapper: &pubmaticWrapperExt{ProfileID: 123, VersionID: 456}, Acat: []string{"drg", "dlu", "ssr"}, - ExtRequest: openrtb_ext.ExtRequest{ - Prebid: openrtb_ext.ExtRequestPrebid{ - BidderParams: json.RawMessage(`{"acat":[" drg \t","dlu","ssr"],"wrapper":{"profile":123,"version":456}}`), - }, - }, }, wantErr: false, }, @@ -259,11 +243,6 @@ func TestExtractPubmaticExtFromRequest(t *testing.T) { }, expectedReqExt: extRequestAdServer{ Wrapper: &pubmaticWrapperExt{ProfileID: 123, VersionID: 456}, - ExtRequest: openrtb_ext.ExtRequest{ - Prebid: openrtb_ext.ExtRequestPrebid{ - BidderParams: json.RawMessage(`{"acat":[1,3,4],"wrapper":{"profile":123,"version":456}}`), - }, - }, }, wantErr: true, }, @@ -277,12 +256,6 @@ func TestExtractPubmaticExtFromRequest(t *testing.T) { expectedReqExt: extRequestAdServer{ Marketplace: &marketplaceReqExt{AllowedBidders: []string{"pubmatic", "groupm"}}, Wrapper: &pubmaticWrapperExt{ProfileID: 123, VersionID: 456}, - ExtRequest: openrtb_ext.ExtRequest{ - Prebid: openrtb_ext.ExtRequestPrebid{ - BidderParams: json.RawMessage(`{"wrapper":{"profile":123,"version":456}}`), - AlternateBidderCodes: &openrtb_ext.ExtAlternateBidderCodes{Enabled: true, Bidders: map[string]openrtb_ext.ExtAdapterAlternateBidderCodes{"pubmatic": {Enabled: true, AllowedBidderCodes: []string{"groupm"}}}}, - }, - }, }, wantErr: false, }, diff --git a/adapters/pubmatic/pubmatictest/exemplary/banner.json b/adapters/pubmatic/pubmatictest/exemplary/banner.json index 2e129128bae..8e505bd3348 100644 --- a/adapters/pubmatic/pubmatictest/exemplary/banner.json +++ b/adapters/pubmatic/pubmatictest/exemplary/banner.json @@ -46,8 +46,7 @@ "id": "1234" } } - }, - + }, "httpCalls": [ { "expectedRequest": { @@ -89,12 +88,7 @@ "profile": 5123, "version":1 }, - "acat": ["drg","dlu","ssr"], - "prebid": { - "bidderparams": { - "acat": ["drg","dlu","ssr"] - } - } + "acat": ["drg","dlu","ssr"] } }, "impIDs":["test-imp-id"] diff --git a/adapters/pubmatic/pubmatictest/exemplary/fledge.json b/adapters/pubmatic/pubmatictest/exemplary/fledge.json index 94d0f000c31..96c8f93ca5c 100644 --- a/adapters/pubmatic/pubmatictest/exemplary/fledge.json +++ b/adapters/pubmatic/pubmatictest/exemplary/fledge.json @@ -47,7 +47,7 @@ } } ], - "ext": {"prebid":{}} + "ext": {} }, "impIDs":["test-imp-id"] }, diff --git a/adapters/pubmatic/pubmatictest/exemplary/native.json b/adapters/pubmatic/pubmatictest/exemplary/native.json index 075a581d5cb..dedabf8af41 100644 --- a/adapters/pubmatic/pubmatictest/exemplary/native.json +++ b/adapters/pubmatic/pubmatictest/exemplary/native.json @@ -56,8 +56,7 @@ "wrapper": { "profile": 5123, "version": 1 - }, - "prebid": {} + } } }, "impIDs":["test-native-imp"] diff --git a/adapters/pubmatic/pubmatictest/exemplary/video.json b/adapters/pubmatic/pubmatictest/exemplary/video.json index f8bdaee6e8c..509f05518dd 100644 --- a/adapters/pubmatic/pubmatictest/exemplary/video.json +++ b/adapters/pubmatic/pubmatictest/exemplary/video.json @@ -53,7 +53,6 @@ } } }, - "httpCalls": [ { "expectedRequest": { @@ -100,12 +99,7 @@ "profile": 5123, "version":1 }, - "acat": ["drg","dlu","ssr"], - "prebid": { - "bidderparams": { - "acat": ["drg","dlu","ssr"] - } - } + "acat": ["drg","dlu","ssr"] } }, "impIDs":["test-video-imp"] diff --git a/adapters/pubmatic/pubmatictest/supplemental/app.json b/adapters/pubmatic/pubmatictest/supplemental/app.json index 67be496c5df..81362f4f011 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/app.json +++ b/adapters/pubmatic/pubmatictest/supplemental/app.json @@ -40,7 +40,6 @@ } } }, - "httpCalls": [ { "expectedRequest": { @@ -81,8 +80,7 @@ "wrapper": { "profile": 5123, "version":1 - }, - "prebid": {} + } } }, "impIDs":["app-imp"] diff --git a/adapters/pubmatic/pubmatictest/supplemental/dctrAndPmZoneID.json b/adapters/pubmatic/pubmatictest/supplemental/dctrAndPmZoneID.json index f16c864e07f..f2a96428b9a 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/dctrAndPmZoneID.json +++ b/adapters/pubmatic/pubmatictest/supplemental/dctrAndPmZoneID.json @@ -92,8 +92,7 @@ "wrapper": { "profile": 5123, "version": 1 - }, - "prebid": {} + } } }, "impIDs":["test-imp-id"] diff --git a/adapters/pubmatic/pubmatictest/supplemental/extra-bid.json b/adapters/pubmatic/pubmatictest/supplemental/extra-bid.json index 0f1e02bf3b1..c14e6ca8e81 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/extra-bid.json +++ b/adapters/pubmatic/pubmatictest/supplemental/extra-bid.json @@ -58,7 +58,6 @@ } } }, - "httpCalls": [ { "expectedRequest": { @@ -103,22 +102,6 @@ "acat": ["drg","dlu","ssr"], "marketplace": { "allowedbidders": ["pubmatic", "groupm"] - }, - "prebid": { - "bidderparams": { - "acat": ["drg","dlu","ssr"] - }, - "alternatebiddercodes": { - "enabled": true, - "bidders": { - "pubmatic": { - "enabled": true, - "allowedbiddercodes": [ - "groupm" - ] - } - } - } } } }, diff --git a/adapters/pubmatic/pubmatictest/supplemental/gptSlotNameInImpExt.json b/adapters/pubmatic/pubmatictest/supplemental/gptSlotNameInImpExt.json index f25e9bd998a..47b4320f2ef 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/gptSlotNameInImpExt.json +++ b/adapters/pubmatic/pubmatictest/supplemental/gptSlotNameInImpExt.json @@ -97,8 +97,7 @@ "wrapper": { "profile": 5123, "version": 1 - }, - "prebid": {} + } } }, "impIDs":["test-imp-id"] diff --git a/adapters/pubmatic/pubmatictest/supplemental/gptSlotNameInImpExtPbAdslot.json b/adapters/pubmatic/pubmatictest/supplemental/gptSlotNameInImpExtPbAdslot.json index 0acc7554ae5..7770d9d8cc5 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/gptSlotNameInImpExtPbAdslot.json +++ b/adapters/pubmatic/pubmatictest/supplemental/gptSlotNameInImpExtPbAdslot.json @@ -93,8 +93,7 @@ "wrapper": { "profile": 5123, "version": 1 - }, - "prebid": {} + } } }, "impIDs":["test-imp-id"] diff --git a/adapters/pubmatic/pubmatictest/supplemental/impExt.json b/adapters/pubmatic/pubmatictest/supplemental/impExt.json index 368dd2fa3dd..5f0c4a89ba6 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/impExt.json +++ b/adapters/pubmatic/pubmatictest/supplemental/impExt.json @@ -84,7 +84,6 @@ } }, "ext": { - "prebid": {}, "wrapper": { "profile": 5123, "version": 1 diff --git a/adapters/pubmatic/pubmatictest/supplemental/invalidparam.json b/adapters/pubmatic/pubmatictest/supplemental/invalidparam.json index 82e9ecef25c..cb226534851 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/invalidparam.json +++ b/adapters/pubmatic/pubmatictest/supplemental/invalidparam.json @@ -94,7 +94,6 @@ } } }, - "expectedMakeRequestsErrors": [ { "value": "Invalid adSlot AdTag_Div1@", diff --git a/adapters/pubmatic/pubmatictest/supplemental/multiplemedia.json b/adapters/pubmatic/pubmatictest/supplemental/multiplemedia.json index 1fcbc2d73dd..293f4dfbabc 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/multiplemedia.json +++ b/adapters/pubmatic/pubmatictest/supplemental/multiplemedia.json @@ -25,7 +25,6 @@ "id": "siteID" } }, - "httpCalls": [ { "expectedRequest": { @@ -54,9 +53,7 @@ "id": "999" } }, - "ext" : { - "prebid": {} - } + "ext" : {} }, "impIDs":["multiple-media-imp"] }, diff --git a/adapters/pubmatic/pubmatictest/supplemental/native_invalid_adm.json b/adapters/pubmatic/pubmatictest/supplemental/native_invalid_adm.json index d5fb862167a..a412bbd207e 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/native_invalid_adm.json +++ b/adapters/pubmatic/pubmatictest/supplemental/native_invalid_adm.json @@ -53,7 +53,6 @@ } }, "ext": { - "prebid": {}, "wrapper": { "profile": 5123, "version": 1 diff --git a/adapters/pubmatic/pubmatictest/supplemental/nilReqExt.json b/adapters/pubmatic/pubmatictest/supplemental/nilReqExt.json index 91cca7490af..d9534a3cb08 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/nilReqExt.json +++ b/adapters/pubmatic/pubmatictest/supplemental/nilReqExt.json @@ -90,8 +90,7 @@ "wrapper": { "profile": 5123, "version": 1 - }, - "prebid": {} + } } }, "impIDs":["test-imp-id"] diff --git a/adapters/pubmatic/pubmatictest/supplemental/noAdSlot.json b/adapters/pubmatic/pubmatictest/supplemental/noAdSlot.json index cd0eb9c2963..79e374cc4ea 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/noAdSlot.json +++ b/adapters/pubmatic/pubmatictest/supplemental/noAdSlot.json @@ -38,7 +38,6 @@ } } }, - "httpCalls": [{ "expectedRequest": { "uri": "https://hbopenbid.pubmatic.com/translator?source=prebid-server", @@ -72,8 +71,7 @@ "wrapper": { "profile": 5123, "version": 1 - }, - "prebid": {} + } } }, "impIDs":["test-imp-id"] diff --git a/adapters/pubmatic/pubmatictest/supplemental/pmZoneIDInKeywords.json b/adapters/pubmatic/pubmatictest/supplemental/pmZoneIDInKeywords.json index 55d8088246e..8d9c7667961 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/pmZoneIDInKeywords.json +++ b/adapters/pubmatic/pubmatictest/supplemental/pmZoneIDInKeywords.json @@ -91,8 +91,7 @@ "wrapper": { "profile": 5123, "version": 1 - }, - "prebid": {} + } } }, "impIDs":["test-imp-id"] diff --git a/adapters/pubmatic/pubmatictest/supplemental/reqBidderParams.json b/adapters/pubmatic/pubmatictest/supplemental/reqBidderParams.json index 3ec9442eba2..4f33b61f6f3 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/reqBidderParams.json +++ b/adapters/pubmatic/pubmatictest/supplemental/reqBidderParams.json @@ -99,14 +99,6 @@ "wrapper": { "profile": 1234, "version": 2 - }, - "prebid": { - "bidderparams": { - "wrapper": { - "profile": 1234, - "version": 2 - } - } } } }, diff --git a/adapters/pubmatic/pubmatictest/supplemental/trimPublisherID.json b/adapters/pubmatic/pubmatictest/supplemental/trimPublisherID.json index 06757c8cc55..1f8f0396eec 100644 --- a/adapters/pubmatic/pubmatictest/supplemental/trimPublisherID.json +++ b/adapters/pubmatic/pubmatictest/supplemental/trimPublisherID.json @@ -89,8 +89,7 @@ "wrapper": { "profile": 5123, "version": 1 - }, - "prebid": {} + } } }, "impIDs":["test-imp-id"]