Skip to content

Commit f6d39e9

Browse files
committed
Expose Test attribute for BidRequest
See 3.2.1 Object: BidRequest, attribute `test`
1 parent 6b2ac63 commit f6d39e9

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

bidrequest.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ type BidRequest struct {
2222
App *App `json:"app,omitempty"`
2323
Device *Device `json:"device,omitempty"`
2424
User *User `json:"user,omitempty"`
25+
Test int `json:"test,omitempty"` // Indicator of test mode in which auctions are not billable, where 0 = live mode, 1 = test mode
2526
AuctionType int `json:"at"` // Auction type, where 1 = First Price, 2 = Second Price Plus. Exchange-specific auction types can be defined using values greater than 500.
2627
TMax int `json:"tmax,omitempty"` // Maximum amount of time in milliseconds to submit a bid
2728
WSeat []string `json:"wseat,omitempty"` // Array of buyer seats allowed to bid on this auction

bidrequest_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ var _ = Describe("BidRequest", func() {
5656
ID: "45asdf987656789adfad4678rew656789",
5757
BuyerUID: "5df678asd8987656asdf78987654",
5858
},
59+
Test: 1,
5960
AuctionType: 2,
6061
TMax: 120,
6162
BAdv: []string{"company1.com", "company2.com"},

testdata/breq.banner.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,5 +48,6 @@
4848
"user": {
4949
"id": "45asdf987656789adfad4678rew656789",
5050
"buyeruid": "5df678asd8987656asdf78987654"
51-
}
51+
},
52+
"test": 1
5253
}

0 commit comments

Comments
 (0)