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

Add storedAuctionResponse on imp level. #3461

Merged
merged 4 commits into from
Oct 1, 2024

Conversation

CTMBNara
Copy link
Collaborator

🔧 Type of changes

  • new bid adapter
  • update bid adapter
  • new feature
  • new analytics adapter
  • new module
  • bugfix
  • documentation
  • configuration
  • tech debt (test coverage, refactorings, etc.)

✨ What's the context?

What's the context for the changes? Are there any

🧠 Rationale behind the change

Why did you choose to make these changes? Were there any trade-offs you had to consider?

🧪 Test plan

How do you know the changes are safe to ship to production?

🏎 Quality check

  • Are your changes following our code style guidelines?
  • Are there any breaking changes in your code?
  • Does your test coverage exceed 90%?
  • Are there any erroneous console logs, debuggers or leftover code in your changes?

Comment on lines +310 to +318
final Map<String, String> storedResponse = new HashMap<>();
storedResponse.put("storedAuctionResponse1", mapper.writeValueAsString(asList(
SeatBid.builder().seat("appnexus").bid(singletonList(Bid.builder().id("id1").build())).build(),
SeatBid.builder().seat("rubicon").bid(singletonList(Bid.builder().id("id3").build())).build())));
storedResponse.put("storedAuctionResponse2", mapper.writeValueAsString(singletonList(
SeatBid.builder().seat("rubicon").bid(singletonList(Bid.builder().id("id2").build())).build())));

given(applicationSettings.getStoredResponses(any(), any())).willReturn(
Future.succeededFuture(StoredResponseDataResult.of(storedResponse, emptyList())));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it has redundant returning values, the test needs only storedAuctionResponse2, also I suggest checking that the first argument of the getStoredResponses contains only storedAuctionResponse2

Comment on lines +125 to +127
.map(impIdToExtPrebid -> Tuple2.of(
impIdToExtPrebid.getKey(),
extractAuctionStoredResponseId(impIdToExtPrebid.getValue())))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why do we use a custom Tuple2 when there is a Pair class from Apache libraries?

@Compile-Ninja Compile-Ninja merged commit 075bdf8 into master Oct 1, 2024
5 checks passed
@Compile-Ninja Compile-Ninja deleted the add-imp-level-stored-auction-response branch October 1, 2024 10:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants