Skip to content

Commit

Permalink
[MODINVSTOR-1243] Attempt increase coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
Saba-Zedginidze-EPAM committed Aug 26, 2024
1 parent 952a8c7 commit ed34dac
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions src/test/java/api/items/TenantItemApiTests.java
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,16 @@ private void createInstanceHoldingItem(ResourceClient itemStorageClient, Resourc
InstanceApiClient.createInstance(okapiHttpClient, smallAngryPlanet(instanceId));
var holdingId = holdingsStorageClient.create(new HoldingRequestBuilder()
.forInstance(instanceId)).getId();
itemStorageClient.create(new ItemRequestBuilder().forHolding(holdingId)
.withBarcode(String.valueOf(Math.random() * 100)));
try {
var item = new ItemRequestBuilder().forHolding(holdingId)
.withBarcode(String.valueOf(Math.random() * 100)).create();
System.err.println(item.toString());
itemStorageClient.create(item);
}
catch (Exception e) {
e.printStackTrace();
throw new RuntimeException(e);
}
}

private List<JsonObject> getItems(OkapiHttpClient okapiHttpClient, int expected)
Expand Down

0 comments on commit ed34dac

Please sign in to comment.