Skip to content

Commit

Permalink
Add placement support to beachfront adapter (#4117)
Browse files Browse the repository at this point in the history
  • Loading branch information
jsalis authored and Mike Chowla committed Aug 27, 2019
1 parent 11801ba commit 9c128af
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions modules/beachfrontBidAdapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@ import { VIDEO, BANNER } from '../src/mediaTypes';
import find from 'core-js/library/fn/array/find';
import includes from 'core-js/library/fn/array/includes';

const ADAPTER_VERSION = '1.6';
const ADAPTER_VERSION = '1.7';
const ADAPTER_NAME = 'BFIO_PREBID';
const OUTSTREAM = 'outstream';

export const VIDEO_ENDPOINT = 'https://reachms.bfmio.com/bid.json?exchange_id=';
export const BANNER_ENDPOINT = 'https://display.bfmio.com/prebid_display';
export const OUTSTREAM_SRC = '//player-cdn.beachfrontmedia.com/playerapi/loader/outstream.js';

export const VIDEO_TARGETING = ['mimes', 'playbackmethod', 'maxduration'];
export const VIDEO_TARGETING = ['mimes', 'playbackmethod', 'maxduration', 'placement'];
export const DEFAULT_MIMES = ['video/mp4', 'application/javascript'];

let appId = '';
Expand Down
5 changes: 3 additions & 2 deletions test/spec/modules/beachfrontBidAdapter_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -226,11 +226,12 @@ describe('BeachfrontAdapter', function () {
const mimes = ['video/webm'];
const playbackmethod = 2;
const maxduration = 30;
const placement = 4;
bidRequest.mediaTypes = { video: {} };
bidRequest.params.video = { mimes, playbackmethod, maxduration };
bidRequest.params.video = { mimes, playbackmethod, maxduration, placement };
const requests = spec.buildRequests([ bidRequest ]);
const data = requests[0].data;
expect(data.imp[0].video).to.deep.contain({ mimes, playbackmethod, maxduration });
expect(data.imp[0].video).to.deep.contain({ mimes, playbackmethod, maxduration, placement });
});

it('must add GDPR consent data to the request', function () {
Expand Down

0 comments on commit 9c128af

Please sign in to comment.