@Test
public void testFindAssetsByTenantIdAndName() {

    UUID assetId1 = UUIDs.timeBased();
    UUID assetId2 = UUIDs.timeBased();
    UUID tenantId1 = UUIDs.timeBased();
    UUID tenantId2 = UUIDs.timeBased();
    UUID customerId1 = UUIDs.timeBased();
    UUID customerId2 = UUIDs.timeBased();
    String name = "TEST_ASSET";
    saveAsset(assetId1, tenantId1, customerId1, name, "TYPE_1");
    saveAsset(assetId2, tenantId2, customerId2, name, "TYPE_1");
    Optional<Asset> assetOpt1 = assetDao.findAssetsByTenantIdAndName(tenantId2, name);
    assertTrue("Optional expected to be non-empty", assetOpt1.isPresent());
    assertEquals(assetId2, assetOpt1.get().getId().getId());
    Optional<Asset> assetOpt2 = assetDao.findAssetsByTenantIdAndName(tenantId2, "NON_EXISTENT_NAME");
    assertFalse("Optional expected to be empty", assetOpt2.isPresent());
}