From ebdf516ff84469c5b904fe4e84b15b235db62619 Mon Sep 17 00:00:00 2001
From: Sagar Khole <sagar.khole@ayanworks.com>
Date: Thu, 9 Jun 2022 17:38:20 +0530
Subject: [PATCH] BDD changes with API / function name

---
 features/proof/findProofByPresentationId.feature   |  5 +++++
 .../proof/sendOutOfBandPresentationRequest.feature | 14 +++++++++++++-
 features/proof/sendPresentationRequest.feature     |  1 +
 ...dPrincipalCredentialPresentationRequest.feature |  1 +
 4 files changed, 20 insertions(+), 1 deletion(-)

diff --git a/features/proof/findProofByPresentationId.feature b/features/proof/findProofByPresentationId.feature
index 3f79e64..caf940c 100644
--- a/features/proof/findProofByPresentationId.feature
+++ b/features/proof/findProofByPresentationId.feature
@@ -3,27 +3,32 @@ Feature: Get Proof Presentation By Id
 
 Scenario: Provide valid presentation id
     Given The presentation id is available on agent database.
+    # controller.ts-> Rest API with GET method -> find-by-presentation-id
     When  provide valid presentation id.
     Then  should return proof presentation details.
 
 Scenario: Provide invalid presentation id
     Given The presentation id available.
+    # controller.ts-> Rest API with GET method -> find-by-presentation-id
     When  provide invalid presentation id.
     Then  should return no data found with status code 404.
 
 Scenario: Provide validated page and pageSize
     Given proof presentation data available on OCM database. 
+    # controller.ts-> Rest API with GET method -> find-proof-presentation
     When  passed valid page.
     And   passed valid pageSize.
     Then  should get proof presentation list.
 
 Scenario: Provide validated page and pageSize
     Given proof presentation data is not available on OCM database.
+    # controller.ts-> Rest API with GET method -> find-proof-presentation
     When  passed valid page.
     And   passed valid pageSize.
     Then  should get http status 404.
     
 Scenario: Not provide a presentation id
     Given The presentation id available.
+    # controller.ts-> Rest API with GET method -> find-by-presentation-id
     When  not provide presentation id.
     Then  should return presentation request required following attributes ( presentation_id ) with status code 400.
\ No newline at end of file
diff --git a/features/proof/sendOutOfBandPresentationRequest.feature b/features/proof/sendOutOfBandPresentationRequest.feature
index b8c631c..6a47aaf 100644
--- a/features/proof/sendOutOfBandPresentationRequest.feature
+++ b/features/proof/sendOutOfBandPresentationRequest.feature
@@ -3,6 +3,7 @@ As a OCM Admin
 
 Scenario: OCM admin verify credentials
     Given PCM user should hold credentials in there wallet.
+    # controller.ts-> Rest API with Post method -> send-out-of-band-presentation-request
     When  OCM verifer orgnization sends a proof presentation request with following fields ( schemaId or credentialDefId, attributes ) to PCM user.
     And   PCM user share the attributes from requested credentials to OCM verifer.
     And   OCM verifer verify the presentation acknowledgement.    
@@ -10,5 +11,16 @@ Scenario: OCM admin verify credentials
 
 Scenario: OCM admin verify credentials
     Given PCM user should hold credentials in there wallet.
+    # controller.ts-> Rest API with Post method -> accept-presentation
     When  OCM admin send a credential request to PCM user.
-    And   PCM user decline the credential request witch will requested from OCM admin.   
+    And   PCM user decline the credential request witch will requested from OCM admin. 
+
+
+    Scenario: OCM admin verify credentials agenst credentialType
+    Given PCM user should hold credentials in there wallet.
+    # controller.ts-> Rest API with Post method -> out-of-band-proof
+    When  OCM verifer orgnization sends a proof presentation request with following fields ( schemaId or credentialDefId, attributes ) to PCM user.
+    And   provide credentialType
+    And   PCM user share the attributes from requested credentials to OCM verifer.
+    And   OCM verifer verify the presentation acknowledgement.    
+    Then  Presentation request should be in 'verified' state.  
diff --git a/features/proof/sendPresentationRequest.feature b/features/proof/sendPresentationRequest.feature
index ad11156..b5b8a43 100644
--- a/features/proof/sendPresentationRequest.feature
+++ b/features/proof/sendPresentationRequest.feature
@@ -4,6 +4,7 @@ As a OCM Admin
 Scenario: OCM admin verify credentials
     Given PCM user should hold credentials in there wallet.
     And   PCM user connection must be in trusted state with verifer.
+    # controller.ts-> Rest API with Post method -> send-presentation-request
     When  OCM verifer orgnization sends a proof presentation request with following fields ( connectionId, schemaId or credentialDefId, attributes ) to PCM user.
     And   PCM user share the attributes from requested credentials to OCM verifer.
     And   OCM verifer verify the presentation acknowledgement.    
diff --git a/features/proof/sendPrincipalCredentialPresentationRequest.feature b/features/proof/sendPrincipalCredentialPresentationRequest.feature
index fd68ed1..c2f1aec 100644
--- a/features/proof/sendPrincipalCredentialPresentationRequest.feature
+++ b/features/proof/sendPrincipalCredentialPresentationRequest.feature
@@ -4,6 +4,7 @@ Feature: I am able to prove as GAIA-X ecosystem member.
 Scenario: Make the existing connection trusted
     Given PCM user should hold principal membership credentials in there wallet.
     And   PCM user connection must be in complete state with verifer.
+    # Nats call on topic 'PROOF_MANAGER_SERVICE/sendMembershipProofRequest'
     When  OCM verifer orgnization sends a proof presentation request with following fields ( schemaId, attributes ) to PCM user.
     And   PCM user share the attributes from requested credentials to OCM verifer.
     And   OCM verifer verify the presentation acknowledgement.    
-- 
GitLab