mirror of
https://github.com/corda/corda.git
synced 2025-06-11 20:01:46 +00:00
Merge pull request #7514 from corda/adel/ENT-9943-v2
ENT-9943: Missed test that had assumed party id was still a long, now…
This commit is contained in:
@ -74,7 +74,7 @@ class FinalityFlowErrorHandlingTest : StateMachineErrorHandlingTest() {
|
|||||||
|
|
||||||
alice.rpc.startFlow(::GetFlowTransaction, txId).returnValue.getOrThrow().apply {
|
alice.rpc.startFlow(::GetFlowTransaction, txId).returnValue.getOrThrow().apply {
|
||||||
assertEquals("V", this.first) // "V" -> VERIFIED
|
assertEquals("V", this.first) // "V" -> VERIFIED
|
||||||
assertEquals(CHARLIE_NAME.hashCode().toLong(), this.second) // peer
|
assertEquals(SecureHash.sha256(CHARLIE_NAME.toString()).toString(), this.second) // peer
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -83,9 +83,9 @@ class FinalityFlowErrorHandlingTest : StateMachineErrorHandlingTest() {
|
|||||||
|
|
||||||
// Internal use for testing only!!
|
// Internal use for testing only!!
|
||||||
@StartableByRPC
|
@StartableByRPC
|
||||||
class GetFlowTransaction(private val txId: SecureHash) : FlowLogic<Pair<String, Long>>() {
|
class GetFlowTransaction(private val txId: SecureHash) : FlowLogic<Pair<String, String>>() {
|
||||||
@Suspendable
|
@Suspendable
|
||||||
override fun call(): Pair<String, Long> {
|
override fun call(): Pair<String, String> {
|
||||||
val transactionStatus = serviceHub.jdbcSession().prepareStatement("select * from node_transactions where tx_id = ?")
|
val transactionStatus = serviceHub.jdbcSession().prepareStatement("select * from node_transactions where tx_id = ?")
|
||||||
.apply { setString(1, txId.toString()) }
|
.apply { setString(1, txId.toString()) }
|
||||||
.use { ps ->
|
.use { ps ->
|
||||||
@ -99,7 +99,7 @@ class GetFlowTransaction(private val txId: SecureHash) : FlowLogic<Pair<String,
|
|||||||
.use { ps ->
|
.use { ps ->
|
||||||
ps.executeQuery().use { rs ->
|
ps.executeQuery().use { rs ->
|
||||||
rs.next()
|
rs.next()
|
||||||
rs.getLong(4) // receiverPartyId
|
rs.getString(4) // receiverPartyId
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return Pair(transactionStatus, receiverPartyId)
|
return Pair(transactionStatus, receiverPartyId)
|
||||||
|
Reference in New Issue
Block a user