Skip to content

Commit

Permalink
OTT-48: Enabled running all tests for TestApplyAdvertiserBlocking and…
Browse files Browse the repository at this point in the history
… corrected syntax error
  • Loading branch information
pm-shriprasad-marathe committed Feb 16, 2021
1 parent 54b073e commit 3db8442
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 30 deletions.
27 changes: 0 additions & 27 deletions exchange/bidder_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1385,33 +1385,6 @@ func wrapWithBidderInfo(bidder adapters.Bidder) adapters.Bidder {
},
},
}
}

var loggerBuffer bytes.Buffer
logger := func(msg string, args ...interface{}) {
loggerBuffer.WriteString(fmt.Sprintf(fmt.Sprintln(msg), args...))
}

bidderAdapter.doRequestImpl(ctx, &bidRequest, logger)

// Wait a little longer than the 205ms mock server sleep.
time.Sleep(210 * time.Millisecond)

logExpected := "TimeoutNotification: error:(context deadline exceeded) body:\n"
logActual := loggerBuffer.String()
assert.EqualValues(t, logExpected, logActual)
}

func wrapWithBidderInfo(bidder adapters.Bidder) adapters.Bidder {
bidderInfo := adapters.BidderInfo{
Status: adapters.StatusActive,
Capabilities: &adapters.CapabilitiesInfo{
App: &adapters.PlatformInfo{
MediaTypes: []openrtb_ext.BidType{openrtb_ext.BidTypeBanner},
},
},
}
>>>>>>> master
return adapters.EnforceBidderInfo(bidder, bidderInfo)
}

Expand Down
3 changes: 0 additions & 3 deletions exchange/exchange_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2950,9 +2950,6 @@ func TestApplyAdvertiserBlocking(t *testing.T) {
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if tt.name != "reject_bid_of_blocked_adv_from_tag_bidder" {
return
}
seatBids := make(map[openrtb_ext.BidderName]*pbsOrtbSeatBid)
tagBidders := make(map[openrtb_ext.BidderName]adapters.Bidder)
getTagBidders = func() map[openrtb_ext.BidderName]adapters.Bidder { return tagBidders }
Expand Down

0 comments on commit 3db8442

Please sign in to comment.