File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
integrationTest/kotlin/com/cosmotech/dataset/service
main/kotlin/com/cosmotech/dataset/service Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -351,7 +351,7 @@ class DatasetServiceIntegrationTest : CsmRedisTestBase() {
351
351
352
352
logger.info(" should find all datasets and assert there are $numberOfDatasets " )
353
353
var datasetList = datasetApiService.findAllDatasets(organizationSaved.id!! , null , null )
354
- assertEquals(numberOfDatasets + 1 , datasetList.size)
354
+ assertEquals(numberOfDatasets, datasetList.size)
355
355
356
356
logger.info(" should find all datasets and assert it equals defaultPageSize: $defaultPageSize " )
357
357
datasetList = datasetApiService.findAllDatasets(organizationSaved.id!! , 0 , null )
@@ -363,7 +363,7 @@ class DatasetServiceIntegrationTest : CsmRedisTestBase() {
363
363
364
364
logger.info(" should find all solutions and assert it returns the second / last page" )
365
365
datasetList = datasetApiService.findAllDatasets(organizationSaved.id!! , 1 , expectedSize)
366
- assertEquals(numberOfDatasets - expectedSize + 1 , datasetList.size)
366
+ assertEquals(numberOfDatasets - expectedSize, datasetList.size)
367
367
}
368
368
369
369
@Test
Original file line number Diff line number Diff line change @@ -155,7 +155,7 @@ class DatasetServiceImpl(
155
155
val currentUser = getCurrentAccountIdentifier(this .csmPlatformProperties)
156
156
datasetRepository.findByOrganizationId(organizationId, currentUser, it).toList()
157
157
} else {
158
- datasetRepository.findAll( it).toList()
158
+ datasetRepository.findByOrganizationIdNoSecurity(organizationId, it).toList()
159
159
}
160
160
}
161
161
} else {
@@ -164,7 +164,7 @@ class DatasetServiceImpl(
164
164
val currentUser = getCurrentAccountIdentifier(this .csmPlatformProperties)
165
165
datasetRepository.findByOrganizationId(organizationId, currentUser, pageable).toList()
166
166
} else {
167
- datasetRepository.findAll( pageable).toList()
167
+ datasetRepository.findByOrganizationIdNoSecurity(organizationId, pageable).toList()
168
168
}
169
169
}
170
170
result.forEach { it.security = updateSecurityVisibility(it).security }
You can’t perform that action at this time.
0 commit comments