Fixed flaky test

This commit is contained in:
Clinton Alexander 2017-10-02 16:12:19 +01:00
parent ed06443ce2
commit 655f2be8b3

View File

@ -124,10 +124,12 @@ class AttachmentLoadingTests : TestDependencyInjectionBase() {
private fun DriverDSLExposedInterface.createTwoNodesAndNotary(): List<NodeHandle> {
val adminUser = User("admin", "admin", permissions = setOf("ALL"))
return listOf(
val nodes = listOf(
startNode(providedName = bankAName, rpcUsers = listOf(adminUser)),
startNode(providedName = bankBName, rpcUsers = listOf(adminUser)),
startNode(providedName = notaryName, rpcUsers = listOf(adminUser), advertisedServices = setOf(ServiceInfo(SimpleNotaryService.type)))
).transpose().getOrThrow() // Wait for all nodes to start up.
nodes.forEach { it.rpc.waitUntilNetworkReady() }
return nodes
}
}