Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
salamonpavel committed May 27, 2024
1 parent 71d98d3 commit 5fd5f88
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ import zio.macros.accessible

@accessible
trait CheckpointController {
def createCheckpointV2(checkpointDTO: CheckpointDTO): IO[ErrorResponse, SingleSuccessResponse[CheckpointDTO]]

def createCheckpointV1(checkpointDTO: CheckpointDTO): IO[ErrorResponse, CheckpointDTO]

def createCheckpointV2(
checkpointDTO: CheckpointDTO
): IO[ErrorResponse, SingleSuccessResponse[CheckpointDTO]]

}
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,11 @@ object PartitioningControllerIntegrationTests extends ZIOSpecDefault with TestDa
),
suite("CreateOrUpdateAdditionalDataSuite")(
test("Returns expected AdditionalDataSubmitDTO") {
assertZIO(PartitioningController.createOrUpdateAdditionalData(additionalDataSubmitDTO1))(
equalTo(SingleSuccessResponse(additionalDataSubmitDTO1))
)
for {
result <- PartitioningController.createOrUpdateAdditionalData(additionalDataSubmitDTO1)
expected = SingleSuccessResponse(additionalDataSubmitDTO1, uuid)
actual = result.copy(requestId = uuid)
} yield assert(actual)(equalTo(expected))
},
test("Returns expected InternalServerErrorResponse") {
assertZIO(PartitioningController.createOrUpdateAdditionalData(additionalDataSubmitDTO2).exit)(
Expand Down

0 comments on commit 5fd5f88

Please sign in to comment.