diff --git a/tests/integration-tests/project/build.properties b/tests/integration-tests/project/build.properties new file mode 100644 index 0000000000..c8fcab543a --- /dev/null +++ b/tests/integration-tests/project/build.properties @@ -0,0 +1 @@ +sbt.version=1.6.2 diff --git a/tests/integration-tests/src/test/kotlin/config/AgentRole.kt b/tests/integration-tests/src/test/kotlin/config/AgentRole.kt index 188ca38296..af518ca38a 100644 --- a/tests/integration-tests/src/test/kotlin/config/AgentRole.kt +++ b/tests/integration-tests/src/test/kotlin/config/AgentRole.kt @@ -2,5 +2,5 @@ package config enum class AgentRole(val roleName: String) { Admin("admin"), - Tenant("tenant"), + Tenant("tenant") } diff --git a/tests/integration-tests/src/test/kotlin/config/Role.kt b/tests/integration-tests/src/test/kotlin/config/Role.kt index 34d2063f3d..149b04aaa9 100644 --- a/tests/integration-tests/src/test/kotlin/config/Role.kt +++ b/tests/integration-tests/src/test/kotlin/config/Role.kt @@ -9,5 +9,5 @@ data class Role( val token: String?, val authHeader: String = "apikey", val webhook: Webhook?, - val agentRole: AgentRole?, + val agentRole: AgentRole? ) diff --git a/tests/integration-tests/src/test/kotlin/config/services/Agent.kt b/tests/integration-tests/src/test/kotlin/config/services/Agent.kt index 6201dfb605..770e95b62c 100644 --- a/tests/integration-tests/src/test/kotlin/config/services/Agent.kt +++ b/tests/integration-tests/src/test/kotlin/config/services/Agent.kt @@ -25,9 +25,9 @@ data class Agent( "OPEN_ENTERPRISE_AGENT_VERSION" to version, "API_KEY_ENABLED" to authEnabled.toString(), "AGENT_DIDCOMM_PORT" to didcommPort.toString(), - "DIDCOMM_SERVICE_URL" to (didcommServiceUrl ?: "http://host.docker.internal:${didcommPort}"), + "DIDCOMM_SERVICE_URL" to (didcommServiceUrl ?: "http://host.docker.internal:$didcommPort"), "AGENT_HTTP_PORT" to httpPort.toString(), - "REST_SERVICE_URL" to (restServiceUrl ?: "http://host.docker.internal:${httpPort}"), + "REST_SERVICE_URL" to (restServiceUrl ?: "http://host.docker.internal:$httpPort"), "PRISM_NODE_PORT" to (prismNode?.httpPort?.toString() ?: ""), "SECRET_STORAGE_BACKEND" to if (vault != null) "vault" else "postgres", "VAULT_HTTP_PORT" to (vault?.httpPort?.toString() ?: ""), diff --git a/tests/integration-tests/src/test/kotlin/features/Init.kt b/tests/integration-tests/src/test/kotlin/features/Init.kt index 77b6579987..6b20d8806d 100644 --- a/tests/integration-tests/src/test/kotlin/features/Init.kt +++ b/tests/integration-tests/src/test/kotlin/features/Init.kt @@ -49,8 +49,8 @@ fun initActors() { .auth().oauth2(actor.recall("BEARER_TOKEN")) .body( CreateWalletRequest( - name = UUID.randomUUID().toString(), - ), + name = UUID.randomUUID().toString() + ) ) .post("/wallets") .then().statusCode(HttpStatus.SC_CREATED) @@ -84,7 +84,7 @@ fun initActors() { config.roles.forEach { role -> cast.actorNamed( role.name, - CallAnApi.at(role.url.toExternalForm()), + CallAnApi.at(role.url.toExternalForm()) ) } if (config.services?.keycloak != null) { diff --git a/tests/integration-tests/src/test/kotlin/features/proofs/AnoncredsPresentProofSteps.kt b/tests/integration-tests/src/test/kotlin/features/proofs/AnoncredsPresentProofSteps.kt index 005e91dd65..f96cd3259b 100644 --- a/tests/integration-tests/src/test/kotlin/features/proofs/AnoncredsPresentProofSteps.kt +++ b/tests/integration-tests/src/test/kotlin/features/proofs/AnoncredsPresentProofSteps.kt @@ -4,12 +4,10 @@ import abilities.ListenToEvents import common.Utils.wait import interactions.Patch import interactions.Post -import io.cucumber.java.en.Then import io.cucumber.java.en.When import io.iohk.atala.automation.extensions.get import io.iohk.atala.automation.serenity.ensure.Ensure import io.iohk.atala.prism.models.* -import models.AnoncredsSchema import models.PresentationEvent import net.serenitybdd.rest.SerenityRest import net.serenitybdd.screenplay.Actor @@ -33,15 +31,15 @@ class AnoncredsPresentProofSteps { val anoncredsPresentationRequestV1 = AnoncredPresentationRequestV1( requestedAttributes = mapOf( "sex" to - AnoncredRequestedAttributeV1( - name = "sex", - restrictions = listOf( - mapOf( - ("attr::sex::value" to "M"), - ("cred_def_id" to credentialDefinitionId) - ) + AnoncredRequestedAttributeV1( + name = "sex", + restrictions = listOf( + mapOf( + ("attr::sex::value" to "M"), + ("cred_def_id" to credentialDefinitionId) ) ) + ) ), requestedPredicates = mapOf( "age" to AnoncredRequestedPredicateV1( @@ -85,7 +83,7 @@ class AnoncredsPresentProofSteps { it.data.thid == bob.recall("thid") } proofEvent != null && - proofEvent!!.data.status == PresentationStatus.Status.REQUEST_RECEIVED + proofEvent!!.data.status == PresentationStatus.Status.REQUEST_RECEIVED }, "ERROR: Bob did not achieve any presentation request!" ) @@ -96,15 +94,15 @@ class AnoncredsPresentProofSteps { fun bobAcceptsTheAnoncredsPresentationWithProof(bob: Actor, faber: Actor) { val requestPresentationAction = RequestPresentationAction( anoncredPresentationRequest = - AnoncredCredentialProofsV1( - listOf( - AnoncredCredentialProofV1( - bob.recall("issuedCredential").recordId, - listOf("sex"), - listOf("age") - ) + AnoncredCredentialProofsV1( + listOf( + AnoncredCredentialProofV1( + bob.recall("issuedCredential").recordId, + listOf("sex"), + listOf("age") ) - ), + ) + ), action = RequestPresentationAction.Action.REQUEST_MINUS_ACCEPT ) diff --git a/tests/integration-tests/src/test/kotlin/features/system/SystemSteps.kt b/tests/integration-tests/src/test/kotlin/features/system/SystemSteps.kt index c9db4a12c2..babe92daf5 100644 --- a/tests/integration-tests/src/test/kotlin/features/system/SystemSteps.kt +++ b/tests/integration-tests/src/test/kotlin/features/system/SystemSteps.kt @@ -48,5 +48,4 @@ class SystemSteps { Ensure.that(metricsResponse.body.asString()).contains("issuance_flow_did_com_exchange_job_ms_gauge") ) } - } diff --git a/tests/integration-tests/src/test/kotlin/features/verificationpolicies/VerificationPoliciesSteps.kt b/tests/integration-tests/src/test/kotlin/features/verificationpolicies/VerificationPoliciesSteps.kt index 9695b79846..d10c2310a3 100644 --- a/tests/integration-tests/src/test/kotlin/features/verificationpolicies/VerificationPoliciesSteps.kt +++ b/tests/integration-tests/src/test/kotlin/features/verificationpolicies/VerificationPoliciesSteps.kt @@ -8,8 +8,8 @@ import io.cucumber.java.en.Then import io.cucumber.java.en.When import io.iohk.atala.automation.extensions.get import io.iohk.atala.automation.serenity.ensure.Ensure -import io.iohk.atala.prism.models.VerificationPolicyResponse import io.iohk.atala.prism.models.VerificationPolicyInput +import io.iohk.atala.prism.models.VerificationPolicyResponse import net.serenitybdd.rest.SerenityRest import net.serenitybdd.screenplay.Actor import org.apache.http.HttpStatus