Skip to content

Commit

Permalink
Code rabbit changes
Browse files Browse the repository at this point in the history
  • Loading branch information
lealobanov committed Nov 9, 2024
1 parent 184c614 commit 2d02e32
Showing 1 changed file with 16 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -465,6 +465,14 @@ class AsyncFlowAccessApiImplTest {
assertSuccess(result, flowTransaction)
}

@Test
fun `test getSystemTransaction failure`() {
`when`(api.getSystemTransaction(any())).thenThrow(testException)

val result = asyncFlowAccessApi.getSystemTransaction(flowId).get()
assertFailure(result, "Failed to get system transaction by block ID", testException)
}

@Test
fun `test getSystemTransactionResult`() {
val flowTransactionResult = FlowTransactionResult(FlowTransactionStatus.SEALED, 1, "message", emptyList(), flowId, HEIGHT, flowId, flowId, 1L)
Expand All @@ -475,6 +483,14 @@ class AsyncFlowAccessApiImplTest {
assertSuccess(result, flowTransactionResult)
}

@Test
fun `test getSystemTransactionResult failure`() {
`when`(api.getSystemTransactionResult(any())).thenThrow(testException)

val result = asyncFlowAccessApi.getSystemTransactionResult(flowId).get()
assertFailure(result, "Failed to get system transaction result by block ID", testException)
}

@Test
fun `test getTransactionResultByIndex success`() {
val index = 0
Expand Down

0 comments on commit 2d02e32

Please sign in to comment.