Skip to content
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
2 changes: 0 additions & 2 deletions src/main/java/org/prebid/server/bidder/aidem/AidemBidder.java
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,6 @@ private static BidType resolveBidType(Bid bid) throws PreBidException {
return switch (markupType) {
case 1 -> BidType.banner;
case 2 -> BidType.video;
case 3 -> BidType.audio;
case 4 -> BidType.xNative;
default -> throw new PreBidException("Unable to fetch mediaType in multi-format: %s"
.formatted(bid.getImpid()));
};
Expand Down
2 changes: 0 additions & 2 deletions src/main/resources/bidder-config/aidem.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,9 @@ adapters:
app-media-types:
- banner
- video
- native
site-media-types:
- banner
- video
- native
supported-vendors:
vendor-id: 0
usersync:
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/static/bidder-params/aidem.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
"placementId": {
"type": "string",
"minLength": 1,
"description": "Unique publisher ttag ID"
"description": "Unique publisher tag ID"
},
"rateLimit": {
"type": "number",
Expand Down
32 changes: 0 additions & 32 deletions src/test/java/org/prebid/server/bidder/aidem/AidemBidderTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,8 @@
import static java.util.function.UnaryOperator.identity;
import static org.assertj.core.api.Assertions.assertThat;
import static org.assertj.core.api.Assertions.assertThatIllegalArgumentException;
import static org.prebid.server.proto.openrtb.ext.response.BidType.audio;
import static org.prebid.server.proto.openrtb.ext.response.BidType.banner;
import static org.prebid.server.proto.openrtb.ext.response.BidType.video;
import static org.prebid.server.proto.openrtb.ext.response.BidType.xNative;

public class AidemBidderTest extends VertxTest {

Expand Down Expand Up @@ -134,36 +132,6 @@ public void makeBidsShouldReturnVideoBidIfMTypeIsTwo() throws JsonProcessingExce
assertThat(result.getValue()).containsOnly(BidderBid.of(Bid.builder().mtype(2).build(), video, "USD"));
}

@Test
public void makeBidsShouldReturnAudioBidIfMTypeIsThree() throws JsonProcessingException {
// given
final BidderCall<BidRequest> httpCall = givenHttpCall(
BidRequest.builder().imp(singletonList(Imp.builder().id("123").build())).build(),
mapper.writeValueAsString(givenBidResponse(Bid.builder().mtype(3).build())));

// when
final Result<List<BidderBid>> result = target.makeBids(httpCall, null);

// then
assertThat(result.getErrors()).isEmpty();
assertThat(result.getValue()).containsOnly(BidderBid.of(Bid.builder().mtype(3).build(), audio, "USD"));
}

@Test
public void makeBidsShouldReturnNativeBidIfMTypeIsFour() throws JsonProcessingException {
// given
final BidderCall<BidRequest> httpCall = givenHttpCall(
BidRequest.builder().imp(singletonList(Imp.builder().id("123").build())).build(),
mapper.writeValueAsString(givenBidResponse(Bid.builder().mtype(4).build())));

// when
final Result<List<BidderBid>> result = target.makeBids(httpCall, null);

// then
assertThat(result.getErrors()).isEmpty();
assertThat(result.getValue()).containsOnly(BidderBid.of(Bid.builder().mtype(4).build(), xNative, "USD"));
}

@Test
public void makeBidsShouldReturnErrorsForBidsThatDoesNotContainMType() throws JsonProcessingException {
// given
Expand Down
Loading