diff --git a/authentication/esignet-integration-impl/src/test/java/io/mosip/authentication/esignet/integration/service/IdaVCIssuancePluginImplTest.java b/authentication/esignet-integration-impl/src/test/java/io/mosip/authentication/esignet/integration/service/IdaVCIssuancePluginImplTest.java index 8ff5ee1a20e..c0a665157b2 100644 --- a/authentication/esignet-integration-impl/src/test/java/io/mosip/authentication/esignet/integration/service/IdaVCIssuancePluginImplTest.java +++ b/authentication/esignet-integration-impl/src/test/java/io/mosip/authentication/esignet/integration/service/IdaVCIssuancePluginImplTest.java @@ -2,7 +2,6 @@ import com.fasterxml.jackson.databind.ObjectMapper; import foundation.identity.jsonld.JsonLDObject; -import io.mosip.authentication.esignet.integration.dto.IdaError; import io.mosip.authentication.esignet.integration.dto.IdaResponseWrapper; import io.mosip.authentication.esignet.integration.dto.IdaVcExchangeRequest; import io.mosip.authentication.esignet.integration.dto.IdaVcExchangeResponse; @@ -220,18 +219,12 @@ public void getVerifiableCredentialWithLinkedDataProof_withInValidDetails_thenFa oidcTransaction.setAuthTransactionId("authTransactionId"); oidcTransaction.setRelyingPartyId("relyingPartyId"); oidcTransaction.setClaimsLocales(new String[]{"en-US", "en", "en-CA", "fr-FR", "fr-CA"}); - - IdaResponseWrapper> mockResponseWrapper = new IdaResponseWrapper<>(); - mockResponseWrapper.setErrors(Collections.singletonList(new IdaError())); - ParameterizedTypeReference>> responseType = - new ParameterizedTypeReference>>() { - }; - + Mockito.when(vciTransactionHelper.getOAuthTransaction(Mockito.any())).thenThrow(new VCIExchangeException("IDA-VCI-003")); try { idaVCIssuancePlugin.getVerifiableCredentialWithLinkedDataProof(vcRequestDto, "holderId", Map.of("accessTokenHash", "ACCESS_TOKEN_HASH", "client_id", "CLIENT_ID")); Assert.fail(); } catch (VCIExchangeException e) { - Assert.assertEquals("vci_exchange_failed", e.getErrorCode()); + Assert.assertEquals("IDA-VCI-003", e.getErrorCode()); } }