-
Notifications
You must be signed in to change notification settings - Fork 224
Test: Fix default value of targeting.hb_pb #4191
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
Test: Fix default value of targeting.hb_pb #4191
Conversation
| assert targetingKeyMap["hb_pb"] == String.format("%,.2f", max.setScale(precision, RoundingMode.DOWN)) | ||
| } | ||
|
|
||
| def "PBS auction shouldn't delete bid and update targeting if price equal zero and dealId it present"() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| def "PBS auction shouldn't delete bid and update targeting if price equal zero and dealId it present"() { | |
| def "PBS auction shouldn't delete bid and update targeting if price equal zero and dealId present"() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add method to the end of the spec.
| and: "Create and save stored response with zero prise into DB" | ||
| def storedBidResponse = BidResponse.getDefaultBidResponse(bidRequest).tap { | ||
| seatbid[0].bid[0].price = 0 | ||
| seatbid[0].bid[0].dealid = PBSUtils.randomNumber | ||
| } | ||
| def storedResponse = new StoredResponse(responseId: storedBidResponseId, storedBidResponse: storedBidResponse) | ||
| storedResponseDao.save(storedResponse) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure, but I hope we can replace storeBidResponse with bidder.setResponse(bidRequest.id, bidResponse)
| assert targetingKeyMap["hb_pb"] == '0.0' | ||
| assert targetingKeyMap["hb_pb_generic"] == '0.0' | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can create a const for "0.0"
8f9d614 to
770da27
Compare
🔧 Type of changes
✨ What's the context?
What's the context for the changes?
🧠 Rationale behind the change
Why did you choose to make these changes? Were there any trade-offs you had to consider?
🔎 New Bid Adapter Checklist
🧪 Test plan
How do you know the changes are safe to ship to production?
🏎 Quality check