diff --git a/integration-test/src/config/.env.dev b/integration-test/src/config/.env.dev index fa03fc4..9ab01ef 100644 --- a/integration-test/src/config/.env.dev +++ b/integration-test/src/config/.env.dev @@ -6,6 +6,7 @@ RECEIPTS_COSMOS_CONN_STRING= RECEIPT_COSMOS_DB_NAME=db RECEIPT_COSMOS_DB_CONTAINER_NAME=receipts RECEIPT_ERROR_COSMOS_DB_CONTAINER_NAME=receipts-message-errors +RECEIPT_MESSAGE_COSMOS_DB_CONTAINER_NAME=receipts-io-messages RECEIPTS_STORAGE_CONN_STRING= BLOB_STORAGE_CONTAINER_NAME=pagopa-d-weu-receipts-azure-blob-receipt-st-attach diff --git a/integration-test/src/config/.env.local b/integration-test/src/config/.env.local index 668c55a..daddf0e 100644 --- a/integration-test/src/config/.env.local +++ b/integration-test/src/config/.env.local @@ -6,6 +6,7 @@ RECEIPTS_COSMOS_CONN_STRING= RECEIPT_COSMOS_DB_NAME=db RECEIPT_COSMOS_DB_CONTAINER_NAME=receipts RECEIPT_ERROR_COSMOS_DB_CONTAINER_NAME=receipts-message-errors +RECEIPT_MESSAGE_COSMOS_DB_CONTAINER_NAME=receipts-io-messages RECEIPTS_STORAGE_CONN_STRING= BLOB_STORAGE_CONTAINER_NAME=pagopa-d-weu-receipts-azure-blob-receipt-st-attach diff --git a/integration-test/src/config/.env.uat b/integration-test/src/config/.env.uat index 72b8ffe..c2decbf 100644 --- a/integration-test/src/config/.env.uat +++ b/integration-test/src/config/.env.uat @@ -6,6 +6,7 @@ RECEIPTS_COSMOS_CONN_STRING= RECEIPT_COSMOS_DB_NAME=db RECEIPT_COSMOS_DB_CONTAINER_NAME=receipts RECEIPT_ERROR_COSMOS_DB_CONTAINER_NAME=receipts-message-errors +RECEIPT_MESSAGE_COSMOS_DB_CONTAINER_NAME=receipts-io-messages RECEIPTS_STORAGE_CONN_STRING= BLOB_STORAGE_CONTAINER_NAME=pagopa-u-weu-receipts-azure-blob-receipt-st-attach diff --git a/integration-test/src/features/receipt_pdf_helpdesk.feature b/integration-test/src/features/receipt_pdf_helpdesk.feature index 0744c48..78bae37 100644 --- a/integration-test/src/features/receipt_pdf_helpdesk.feature +++ b/integration-test/src/features/receipt_pdf_helpdesk.feature @@ -27,7 +27,7 @@ Feature: All about payment events to recover managed by Azure functions receipt- Scenario: getReceiptMessage API return receipt-error stored on datastore Given a receipt-io-message with bizEventId "receipt-helpdesk-int-test-id-3" and messageId "receipt-helpdesk-int-test-message-id-3" stored into receipt-io-message datastore - When getReceiptMessage API is called with messageId "receipt-helpdesk-int-test-id-3" + When getReceiptMessage API is called with messageId "receipt-helpdesk-int-test-message-id-3" Then the api response has a 200 Http status And the receipt-message has messageId "receipt-helpdesk-int-test-message-id-3" And the receipt-message has eventId "receipt-helpdesk-int-test-id-3" diff --git a/integration-test/src/step_definitions/receipt_pdf_helpdesk_step.js b/integration-test/src/step_definitions/receipt_pdf_helpdesk_step.js index 277d943..6a22f82 100644 --- a/integration-test/src/step_definitions/receipt_pdf_helpdesk_step.js +++ b/integration-test/src/step_definitions/receipt_pdf_helpdesk_step.js @@ -248,7 +248,7 @@ Then("wait {int} ms", async function (milliSec) { sleep(milliSec) }); -Given('a receipt-io-message with bizEventId {string} and status {string} stored into receipt-error datastore', async function (eventId, messageId) { +Given('a receipt-io-message with bizEventId {string} and messageId {string} stored into receipt-io-message datastore', async function (eventId, messageId) { messageId = messageId; // prior cancellation to avoid dirty cases await deleteDocumentFromReceiptMessageDatastore(messageId); diff --git a/integration-test/src/step_definitions/receipts_datastore_client.js b/integration-test/src/step_definitions/receipts_datastore_client.js index b5ad050..5936f77 100644 --- a/integration-test/src/step_definitions/receipts_datastore_client.js +++ b/integration-test/src/step_definitions/receipts_datastore_client.js @@ -63,7 +63,7 @@ async function createDocumentInReceiptErrorDatastore(id, status) { async function createDocumentInReceiptIoMessageDatastore(eventId, messageId) { let message = createReceiptMessage(eventId, messageId); try { - return await receiptMessageContainer.items.create(receipt); + return await receiptMessageContainer.items.create(message); } catch (err) { console.log(err); }