Skip to content

Commit

Permalink
Unit test update to include file uri
Browse files Browse the repository at this point in the history
  • Loading branch information
maallen committed Oct 15, 2024
1 parent 9ffc1d6 commit eb49be3
Showing 1 changed file with 25 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -197,34 +197,49 @@ public void mapMojitoAndThirdPartyTextUnits() throws InterruptedException, Execu
.extracting(
t -> t.getAsset().getId(),
com.box.l10n.mojito.entity.ThirdPartyTextUnit::getThirdPartyId,
t -> t.getTmTextUnit().getId())
t -> t.getTmTextUnit().getId(),
com.box.l10n.mojito.entity.ThirdPartyTextUnit::getUploadedFileUri)
.containsExactly(
tuple(asset.getId(), "3rd-hello", thirdPartyServiceTestData.tmTextUnitHello.getId()),
tuple(asset.getId(), "3rd-bye", thirdPartyServiceTestData.tmTextUnitBye.getId()),
tuple(
asset.getId(),
"3rd-hello",
thirdPartyServiceTestData.tmTextUnitHello.getId(),
"testFileUri"),
tuple(
asset.getId(),
"3rd-bye",
thirdPartyServiceTestData.tmTextUnitBye.getId(),
"testFileUri"),
tuple(
asset.getId(),
"3rd-plural_things",
thirdPartyServiceTestData.tmTextUnitPluralThingsZero.getId()),
thirdPartyServiceTestData.tmTextUnitPluralThingsZero.getId(),
"testFileUri"),
tuple(
asset.getId(),
"3rd-plural_things",
thirdPartyServiceTestData.tmTextUnitPluralThingsOne.getId()),
thirdPartyServiceTestData.tmTextUnitPluralThingsOne.getId(),
"testFileUri"),
tuple(
asset.getId(),
"3rd-plural_things",
thirdPartyServiceTestData.tmTextUnitPluralThingsTwo.getId()),
thirdPartyServiceTestData.tmTextUnitPluralThingsTwo.getId(),
"testFileUri"),
tuple(
asset.getId(),
"3rd-plural_things",
thirdPartyServiceTestData.tmTextUnitPluralThingsFew.getId()),
thirdPartyServiceTestData.tmTextUnitPluralThingsFew.getId(),
"testFileUri"),
tuple(
asset.getId(),
"3rd-plural_things",
thirdPartyServiceTestData.tmTextUnitPluralThingsMany.getId()),
thirdPartyServiceTestData.tmTextUnitPluralThingsMany.getId(),
"testFileUri"),
tuple(
asset.getId(),
"3rd-plural_things",
thirdPartyServiceTestData.tmTextUnitPluralThingsOther.getId()));
thirdPartyServiceTestData.tmTextUnitPluralThingsOther.getId(),
"testFileUri"));

logger.debug("Verify behavior");
verify(thirdPartyTMSMock, times(3))
Expand Down Expand Up @@ -741,6 +756,7 @@ ThirdPartyTextUnit createThirdPartyTextUnit(
thirdPartyTextUnit.setId(id);
thirdPartyTextUnit.setName(name);
thirdPartyTextUnit.setNamePluralPrefix(isNamePluralPrefix);
thirdPartyTextUnit.setUploadedFileUri("testFileUri");
return thirdPartyTextUnit;
}
}

0 comments on commit eb49be3

Please sign in to comment.