Skip to content

Commit

Permalink
Merge pull request #3086 from wordpress-mobile/issue/12390-update-mod…
Browse files Browse the repository at this point in the history
…els-to-support-evergreen-campaigns

Add new isEndless field to support Blaze Evergreen campaigns
  • Loading branch information
irfano authored Aug 29, 2024
2 parents 651ba46 + 4ee8985 commit a04837a
Show file tree
Hide file tree
Showing 11 changed files with 987 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,8 @@ class BlazeCampaignsRestClientTest {
durationDays = DURATION_IN_DAYS,
startTime = CREATED_AT,
targetUrn = "urn:wpcom:post:199247490:9",
status = UI_STATUS
status = UI_STATUS,
isEvergreen = false
)

val BLAZE_CAMPAIGNS_RESPONSE = BlazeCampaignListResponse(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,7 @@ class BlazeCampaignsDaoTest {
targetUrn = TARGET_URN,
totalBudget = TOTAL_BUDGET,
spentBudget = SPENT_BUDGET,
isEndlessCampaign = false
)
val BLAZE_CAMPAIGNS_MODEL = BlazeCampaignsModel(
campaigns = listOf(BLAZE_CAMPAIGN_MODEL),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,8 @@ private val CAMPAIGN_RESPONSE = BlazeCampaign(
durationDays = DURATION_IN_DAYS,
startTime = CREATED_AT,
targetUrn = TARGET_URN,
status = UI_STATUS
status = UI_STATUS,
isEvergreen = false
)

private val BLAZE_CAMPAIGNS_RESPONSE = BlazeCampaignListResponse(
Expand All @@ -106,7 +107,8 @@ private val BLAZE_CAMPAIGN_ENTITY = BlazeCampaignEntity(
clicks = CLICKS,
targetUrn = TARGET_URN,
totalBudget = TOTAL_BUDGET,
spentBudget = SPENT_BUDGET
spentBudget = SPENT_BUDGET,
isEndlessCampaign = false
)
private val BLAZE_CAMPAIGNS_MODEL = BlazeCampaignsModel(
campaigns = listOf(BLAZE_CAMPAIGN_ENTITY.toDomainModel()),
Expand Down Expand Up @@ -458,6 +460,7 @@ class BlazeCampaignsStoreTest {
targetUrn = TARGET_URN,
totalBudget = TOTAL_BUDGET,
spentBudget = SPENT_BUDGET,
isEndlessCampaign = false
)

whenever(creationRestClient.createCampaign(any(), any())).thenReturn(
Expand Down
Loading

0 comments on commit a04837a

Please sign in to comment.