Skip to content

Commit

Permalink
Drop usage of Object.entries in tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
slimkrazy committed Oct 23, 2020
1 parent 28f19c6 commit 2befbd8
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions test/spec/modules/aolBidAdapter_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -490,16 +490,19 @@ describe('AolAdapter', function () {
'&param1=val1&param2=val2&param3=val3&param4=val4');
});

for (const [source, idValue] of Object.entries(SUPPORTED_USER_ID_SOURCES)) {
it(`should set the user ID query param for ${source}`, function () {
let bidRequest = createCustomBidRequest({
params: getNexageGetBidParams()
for (let source in SUPPORTED_USER_ID_SOURCES) {
if (SUPPORTED_USER_ID_SOURCES.hasOwnProperty(source)) {
let idValue = SUPPORTED_USER_ID_SOURCES[source];
it(`should set the user ID query param for ${source}`, function () {
let bidRequest = createCustomBidRequest({
params: getNexageGetBidParams()
});
bidRequest.bids[0].userId = {};
bidRequest.bids[0].userIdAsEids = createEidsArray(USER_ID_DATA);
let [request] = spec.buildRequests(bidRequest.bids);
expect(request.url).to.contain(`&eid${source}=${encodeURIComponent(idValue)}`);
});
bidRequest.bids[0].userId = {};
bidRequest.bids[0].userIdAsEids = createEidsArray(USER_ID_DATA);
let [request] = spec.buildRequests(bidRequest.bids);
expect(request.url).to.contain(`&eid${source}=${encodeURIComponent(idValue)}`);
});
}
}

it('should return request object for One Mobile POST endpoint when POST configuration is present', function () {
Expand Down

0 comments on commit 2befbd8

Please sign in to comment.