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

XCH-821 Eliminate preflight #6

Merged
merged 1 commit into from
Jul 25, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions modules/33acrossBidAdapter.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,10 @@ function _createServerRequest(bidRequest) {
}

/*
* Now construt the full server request
* Now construct the full server request
*/
const options = {
contentType: 'application/json',
contentType: 'text/plain',
withCredentials: true
};
// Allow the ability to configure the HB endpoint for testing purposes.
Expand Down
67 changes: 2 additions & 65 deletions modules/33acrossBidAdapter.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,72 +24,9 @@ var adUnits = [
bids: [{
bidder: '33across',
params: {
siteId: 'pub1234',
productId: 'infeed'
siteId: 'examplePub1234',
productId: 'siab'
}
}]
}
```

# Ad Unit and Setup: For Testing
In order to receive bids please map localhost to (any) test domain.

```
<--! Prebid Config section >
<script>
var PREBID_TIMEOUT = 3000;
var adUnits = [
{
code: '33across-hb-ad-123456-1',
sizes: [
[300, 250],
[728, 90]
],
bids: [{
bidder: '33across',
params: {
site: {
id: 'aRlI5W_9yr5jkxacwqm_6r',
page: "http://thinkbabynames.com/baby-mcbabyface",
ext: {
ttx: {
ssp_configs: [
{
"name": "index",
"enabled": false
},
{
"name": "rubicon",
"enabled": true
},
{
"name": "33xchange",
"enabled": false
}
]
}
}
},
productId: 'infeed'
}
}]
}
];

var pbjs = pbjs || {};
pbjs.que = pbjs.que || [];

// Adjust bid CPM to ensure it wins the auction (USED ONLY FOR TESTING). Need to do this since test bids have too low a CPM
pbjs.bidderSettings = {
'33across': {
bidCpmAdjustment : function(bidCpm, bid){
// adjust the bid in real time before the auction takes place, only do so for valid bids ignore no bids
if (bid.w !== 0 && bid.h !== 0 && bidCpm !== 0) {
return bidCpm + 0.50;
}
}
}
};
</script>
<!-- End Prebid Config section>
```
8 changes: 4 additions & 4 deletions test/spec/modules/33acrossBidAdapter_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ describe('33acrossBidAdapter:', function () {
'url': END_POINT,
'data': JSON.stringify(ttxRequest),
'options': {
'contentType': 'application/json',
'contentType': 'text/plain',
'withCredentials': true
}
}
Expand Down Expand Up @@ -193,7 +193,7 @@ describe('33acrossBidAdapter:', function () {
url: 'https://foo.com/hb/',
data: JSON.stringify(ttxRequest),
options: {
contentType: 'application/json',
contentType: 'text/plain',
withCredentials: true
}
};
Expand Down Expand Up @@ -243,7 +243,7 @@ describe('33acrossBidAdapter:', function () {
url: 'https://foo.com/hb/',
data: JSON.stringify(ttxRequest),
options: {
contentType: 'application/json',
contentType: 'text/plain',
withCredentials: true
}
};
Expand Down Expand Up @@ -293,7 +293,7 @@ describe('33acrossBidAdapter:', function () {
url: '//staging-ssc.33across.com/api/v1/hb',
data: JSON.stringify(this.ttxRequest),
options: {
contentType: 'application/json',
contentType: 'text/plain',
withCredentials: false
}
};
Expand Down