Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LunamediaHB bid adapter #5906

Merged
merged 13 commits into from
Nov 6, 2020
Prev Previous commit
Next Next commit
Update lunamediahbBidAdapter_spec.js
  • Loading branch information
lunamedia authored Nov 5, 2020
commit 39de8276bb4e4408ac2bd25d62c1e1e7342265f4
23 changes: 10 additions & 13 deletions test/spec/modules/lunamediahbBidAdapter_spec.js
Original file line number Diff line number Diff line change
@@ -201,12 +201,10 @@ describe('LunamediaHBBidAdapter', function () {
const native = {
body: [{
mediaType: 'native',
native: {
clickUrl: 'test.com',
title: 'Test',
image: 'test.com',
impressionTrackers: ['test.com'],
},
clickUrl: 'test.com',
title: 'Test',
image: 'test.com',
impressionTrackers: ['test.com'],
ttl: 120,
cpm: 0.4,
requestId: '23fhj33i987f',
@@ -219,15 +217,14 @@ describe('LunamediaHBBidAdapter', function () {
expect(nativeResponses).to.be.an('array').that.is.not.empty;

let dataItem = nativeResponses[0];
expect(dataItem).to.have.keys('requestId', 'cpm', 'ttl', 'creativeId', 'netRevenue', 'currency', 'mediaType', 'native');
expect(dataItem.native).to.have.keys('clickUrl', 'impressionTrackers', 'title', 'image')
expect(dataItem).to.have.keys('requestId', 'cpm', 'ttl', 'creativeId', 'netRevenue', 'currency', 'mediaType', 'clickUrl', 'impressionTrackers', 'title', 'image');
expect(dataItem.requestId).to.equal('23fhj33i987f');
expect(dataItem.cpm).to.equal(0.4);
expect(dataItem.native.clickUrl).to.equal('test.com');
expect(dataItem.native.title).to.equal('Test');
expect(dataItem.native.image).to.equal('test.com');
expect(dataItem.native.impressionTrackers).to.be.an('array').that.is.not.empty;
expect(dataItem.native.impressionTrackers[0]).to.equal('test.com');
expect(dataItem.clickUrl).to.equal('test.com');
expect(dataItem.title).to.equal('Test');
expect(dataItem.image).to.equal('test.com');
expect(dataItem.impressionTrackers).to.be.an('array').that.is.not.empty;
expect(dataItem.impressionTrackers[0]).to.equal('test.com');
expect(dataItem.ttl).to.equal(120);
expect(dataItem.creativeId).to.equal('2');
expect(dataItem.netRevenue).to.be.true;