@@ -28,7 +28,7 @@ describe('Adot Adapter', function () {
28
28
it ( 'should build request (banner)' , function ( ) {
29
29
const bidderRequestId = 'bidderRequestId' ;
30
30
const validBidRequests = [ { bidderRequestId, mediaTypes : { } } , { bidderRequestId, bidId : 'bidId' , mediaTypes : { banner : { sizes : [ [ 300 , 250 ] ] } } , params : { placementId : 'placementId' , adUnitCode : 200 } } ] ;
31
- const bidderRequest = { position : 2 , refererInfo : { page : 'http://localhost.com' , domain : 'localhost.com' } , gdprConsent : { consentString : 'consentString' , gdprApplies : true } } ;
31
+ const bidderRequest = { position : 2 , refererInfo : { page : 'http://localhost.com' , domain : 'localhost.com' } , gdprConsent : { consentString : 'consentString' , gdprApplies : true } , userId : { pubProvidedId : 'userId' } , schain : { ver : '1.0' } } ;
32
32
33
33
const request = spec . buildRequests ( validBidRequests , bidderRequest ) ;
34
34
const buildBidRequestResponse = {
@@ -54,10 +54,11 @@ describe('Adot Adapter', function () {
54
54
publisher : {
55
55
// id: 'adot'
56
56
id : undefined
57
- }
57
+ } ,
58
+ ext : { schain : { ver : '1.0' } }
58
59
} ,
59
60
device : { ua : navigator . userAgent , language : navigator . language } ,
60
- user : { ext : { consent : bidderRequest . gdprConsent . consentString } } ,
61
+ user : { ext : { consent : bidderRequest . gdprConsent . consentString , pubProvidedId : 'userId' } } ,
61
62
regs : { ext : { gdpr : bidderRequest . gdprConsent . gdprApplies } } ,
62
63
ext : {
63
64
adot : { adapter_version : 'v2.0.0' } ,
@@ -76,7 +77,7 @@ describe('Adot Adapter', function () {
76
77
it ( 'should build request (native)' , function ( ) {
77
78
const bidderRequestId = 'bidderRequestId' ;
78
79
const validBidRequests = [ { bidderRequestId, mediaTypes : { } } , { bidderRequestId, bidId : 'bidId' , mediaTypes : { native : { title : { required : true , len : 50 , sizes : [ [ 300 , 250 ] ] } , wrong : { } , image : { } } } , params : { placementId : 'placementId' , adUnitCode : 200 } } ] ;
79
- const bidderRequest = { position : 2 , refererInfo : { page : 'http://localhost.com' , domain : 'localhost.com' } , gdprConsent : { consentString : 'consentString' , gdprApplies : true } } ;
80
+ const bidderRequest = { position : 2 , refererInfo : { page : 'http://localhost.com' , domain : 'localhost.com' } , gdprConsent : { consentString : 'consentString' , gdprApplies : true } , userId : { pubProvidedId : 'userId' } , schain : { ver : '1.0' } } ;
80
81
81
82
const request = spec . buildRequests ( validBidRequests , bidderRequest ) ;
82
83
const buildBidRequestResponse = {
@@ -101,10 +102,11 @@ describe('Adot Adapter', function () {
101
102
publisher : {
102
103
// id: 'adot'
103
104
id : undefined
104
- }
105
+ } ,
106
+ ext : { schain : { ver : '1.0' } }
105
107
} ,
106
108
device : { ua : navigator . userAgent , language : navigator . language } ,
107
- user : { ext : { consent : bidderRequest . gdprConsent . consentString } } ,
109
+ user : { ext : { consent : bidderRequest . gdprConsent . consentString , pubProvidedId : 'userId' } } ,
108
110
regs : { ext : { gdpr : bidderRequest . gdprConsent . gdprApplies } } ,
109
111
ext : {
110
112
adot : { adapter_version : 'v2.0.0' } ,
@@ -123,7 +125,7 @@ describe('Adot Adapter', function () {
123
125
it ( 'should build request (video)' , function ( ) {
124
126
const bidderRequestId = 'bidderRequestId' ;
125
127
const validBidRequests = [ { bidderRequestId, mediaTypes : { } } , { bidderRequestId, bidId : 'bidId' , mediaTypes : { video : { playerSize : [ [ 300 , 250 ] ] , minduration : 1 , maxduration : 2 , api : 'api' , linearity : 'linearity' , mimes : [ ] , placement : 'placement' , playbackmethod : 'playbackmethod' , protocols : 'protocol' , startdelay : 'startdelay' } } , params : { placementId : 'placementId' , adUnitCode : 200 } } ] ;
126
- const bidderRequest = { position : 2 , refererInfo : { page : 'http://localhost.com' , domain : 'localhost.com' } , gdprConsent : { consentString : 'consentString' , gdprApplies : true } } ;
128
+ const bidderRequest = { position : 2 , refererInfo : { page : 'http://localhost.com' , domain : 'localhost.com' } , gdprConsent : { consentString : 'consentString' , gdprApplies : true } , userId : { pubProvidedId : 'userId' } , schain : { ver : '1.0' } } ;
127
129
128
130
const request = spec . buildRequests ( validBidRequests , bidderRequest ) ;
129
131
const buildBidRequestResponse = {
@@ -160,10 +162,11 @@ describe('Adot Adapter', function () {
160
162
publisher : {
161
163
// id: 'adot'
162
164
id : undefined
163
- }
165
+ } ,
166
+ ext : { schain : { ver : '1.0' } }
164
167
} ,
165
168
device : { ua : navigator . userAgent , language : navigator . language } ,
166
- user : { ext : { consent : bidderRequest . gdprConsent . consentString } } ,
169
+ user : { ext : { consent : bidderRequest . gdprConsent . consentString , pubProvidedId : 'userId' } } ,
167
170
regs : { ext : { gdpr : bidderRequest . gdprConsent . gdprApplies } } ,
168
171
ext : {
169
172
adot : { adapter_version : 'v2.0.0' } ,
0 commit comments