Skip to content

Commit 13fabed

Browse files
committed
apply spotless formatting
1 parent 9f04491 commit 13fabed

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

dataset/src/main/kotlin/com/cosmotech/dataset/service/DatasetServiceImpl.kt

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -330,16 +330,18 @@ class DatasetServiceImpl(
330330
DatasetSourceType.AzureStorage -> {
331331
if (dataset.status == Dataset.Status.PENDING) {
332332
dataset.source!!.takeIf { !it.jobId.isNullOrEmpty() }
333-
?: throw IllegalStateException("Dataset doesn't have a job id to get status from. Refresh dataset first.")
333+
?: throw IllegalStateException(
334+
"Dataset doesn't have a job id to get status from. Refresh dataset first.")
334335
val twingraphImportJobInfoRequest =
335-
TwingraphImportJobInfoRequest(this, dataset.source!!.jobId!!, organizationId)
336+
TwingraphImportJobInfoRequest(this, dataset.source!!.jobId!!, organizationId)
336337

337338
this.eventPublisher.publishEvent(twingraphImportJobInfoRequest)
338339

339340
dataset.apply {
340341
when (twingraphImportJobInfoRequest.response) {
341342
"Succeeded" -> status = Dataset.Status.READY
342-
"Error", "Failed" -> status = Dataset.Status.ERROR
343+
"Error",
344+
"Failed" -> status = Dataset.Status.ERROR
343345
}
344346
datasetRepository.save(this)
345347
}

dataset/src/test/kotlin/com/cosmotech/dataset/service/DatasetServiceImplTests.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -347,8 +347,7 @@ class DatasetServiceImplTests {
347347
source = SourceInfo(location = "test", jobId = "0"),
348348
twingraphId = "twingraphId")
349349
mockkConstructor(TwingraphImportJobInfoRequest::class)
350-
every { anyConstructed<TwingraphImportJobInfoRequest>().response } returns
351-
"Succeeded"
350+
every { anyConstructed<TwingraphImportJobInfoRequest>().response } returns "Succeeded"
352351
every { datasetRepository.findById(DATASET_ID) } returns Optional.of(dataset)
353352
every { csmJedisPool.resource.exists(any<String>()) } returns true
354353
every { datasetRepository.save(any()) } returnsArgument 0

0 commit comments

Comments
 (0)