Skip to content

Commit

Permalink
Fix transfer_received_at unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
philipliu committed Oct 24, 2023
1 parent 14db152 commit 58b98ee
Show file tree
Hide file tree
Showing 8 changed files with 18 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -480,6 +480,7 @@ class NotifyOffchainFundsAvailableHandlerTest {
expectedResponse.status = PENDING_USR_TRANSFER_COMPLETE
expectedResponse.externalTransactionId = EXTERNAL_TX_ID
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.customers =
Customers(StellarId(CUSTOMER_ID, null), StellarId(CUSTOMER_ID, null))
Expand Down Expand Up @@ -555,6 +556,7 @@ class NotifyOffchainFundsAvailableHandlerTest {
expectedResponse.kind = PlatformTransactionData.Kind.from(kind)
expectedResponse.status = PENDING_USR_TRANSFER_COMPLETE
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.customers =
Customers(StellarId(CUSTOMER_ID, null), StellarId(CUSTOMER_ID, null))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -558,6 +558,7 @@ class NotifyOffchainFundsPendingHandlerTest {
expectedResponse.status = PENDING_EXTERNAL
expectedResponse.externalTransactionId = EXTERNAL_TX_ID
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.customers =
Customers(StellarId(CUSTOMER_ID, null), StellarId(CUSTOMER_ID, null))
Expand Down Expand Up @@ -633,6 +634,7 @@ class NotifyOffchainFundsPendingHandlerTest {
expectedResponse.kind = Kind.from(kind)
expectedResponse.status = PENDING_EXTERNAL
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.customers =
Customers(StellarId(CUSTOMER_ID, null), StellarId(CUSTOMER_ID, null))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -748,6 +748,7 @@ class NotifyOffchainFundsReceivedHandlerTest {
expectedResponse.status = PENDING_ANCHOR
expectedResponse.externalTransactionId = EXTERNAL_TX_ID
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.amountIn = Amount("1", FIAT_USD)
expectedResponse.amountOut = Amount("0.9", STELLAR_USDC)
expectedResponse.amountFee = Amount("0.1", STELLAR_USDC)
Expand Down Expand Up @@ -834,6 +835,7 @@ class NotifyOffchainFundsReceivedHandlerTest {
expectedResponse.kind = Kind.from(kind)
expectedResponse.status = PENDING_ANCHOR
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = sep6TxnCapture.captured.transferReceivedAt
expectedResponse.amountIn = Amount("1", FIAT_USD)
expectedResponse.amountExpected = Amount(null, FIAT_USD)
expectedResponse.customers =
Expand Down Expand Up @@ -918,6 +920,7 @@ class NotifyOffchainFundsReceivedHandlerTest {
expectedResponse.status = PENDING_ANCHOR
expectedResponse.externalTransactionId = EXTERNAL_TX_ID
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = sep6TxnCapture.captured.transferReceivedAt
expectedResponse.amountExpected = Amount(null, FIAT_USD)
expectedResponse.customers =
Customers(StellarId(CUSTMOMER_ID, null), StellarId(CUSTMOMER_ID, null))
Expand Down Expand Up @@ -995,6 +998,7 @@ class NotifyOffchainFundsReceivedHandlerTest {
expectedResponse.kind = Kind.from(kind)
expectedResponse.status = PENDING_ANCHOR
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = sep6TxnCapture.captured.transferReceivedAt
expectedResponse.amountExpected = Amount(null, FIAT_USD)
expectedResponse.customers =
Customers(StellarId(CUSTMOMER_ID, null), StellarId(CUSTMOMER_ID, null))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -740,6 +740,7 @@ class NotifyOffchainFundsSentHandlerTest {
expectedResponse.status = PENDING_EXTERNAL
expectedResponse.externalTransactionId = EXTERNAL_TX_ID
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.customers =
Customers(StellarId(CUSTOMER_ID, null), StellarId(CUSTOMER_ID, null))
Expand Down Expand Up @@ -819,6 +820,7 @@ class NotifyOffchainFundsSentHandlerTest {
expectedResponse.status = PENDING_EXTERNAL
expectedResponse.externalTransactionId = EXTERNAL_TX_ID
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = sep6TxnCapture.captured.transferReceivedAt
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.customers =
Customers(StellarId(CUSTOMER_ID, null), StellarId(CUSTOMER_ID, null))
Expand Down Expand Up @@ -977,6 +979,7 @@ class NotifyOffchainFundsSentHandlerTest {
expectedResponse.status = COMPLETED
expectedResponse.externalTransactionId = EXTERNAL_TX_ID
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.completedAt = sep6TxnCapture.captured.completedAt
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.customers =
Expand Down Expand Up @@ -1056,6 +1059,7 @@ class NotifyOffchainFundsSentHandlerTest {
expectedResponse.kind = PlatformTransactionData.Kind.from(kind)
expectedResponse.status = COMPLETED
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.completedAt = sep6TxnCapture.captured.completedAt
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.customers =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -795,6 +795,7 @@ class NotifyOnchainFundsReceivedHandlerTest {
expectedResponse.kind = PlatformTransactionData.Kind.from(kind)
expectedResponse.status = PENDING_ANCHOR
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = Instant.parse(STELLAR_PAYMENT_DATE)
expectedResponse.amountIn = Amount("1", FIAT_USD)
expectedResponse.amountOut = Amount("0.9", STELLAR_USDC)
expectedResponse.amountFee = Amount("0.1", STELLAR_USDC)
Expand Down Expand Up @@ -894,6 +895,7 @@ class NotifyOnchainFundsReceivedHandlerTest {
expectedResponse.kind = PlatformTransactionData.Kind.from(kind)
expectedResponse.status = PENDING_ANCHOR
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = Instant.parse(STELLAR_PAYMENT_DATE)
expectedResponse.amountIn = Amount("1", FIAT_USD)
expectedResponse.amountExpected = Amount(null, FIAT_USD)
expectedResponse.stellarTransactions = stellarTransactions
Expand Down Expand Up @@ -987,6 +989,7 @@ class NotifyOnchainFundsReceivedHandlerTest {
expectedResponse.kind = PlatformTransactionData.Kind.from(kind)
expectedResponse.status = PENDING_ANCHOR
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = Instant.parse(STELLAR_PAYMENT_DATE)
expectedResponse.amountExpected = Amount(null, FIAT_USD)
expectedResponse.stellarTransactions = stellarTransactions
expectedResponse.customers =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -471,6 +471,7 @@ class NotifyOnchainFundsSentHandlerTest {
expectedResponse.kind = PlatformTransactionData.Kind.from(kind)
expectedResponse.status = COMPLETED
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.completedAt = sep6TxnCapture.captured.completedAt
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.stellarTransactions = stellarTransactions
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,7 @@ class NotifyTransactionRecoveryHandlerTest {
expectedResponse.status = PENDING_ANCHOR
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.customers =
Customers(StellarId(CUSTOMER_ID, null), StellarId(CUSTOMER_ID, null))

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -404,6 +404,7 @@ class RequestTrustlineHandlerTest {
expectedResponse.status = PENDING_TRUST
expectedResponse.amountExpected = Amount(null, "")
expectedResponse.updatedAt = sep6TxnCapture.captured.updatedAt
expectedResponse.transferReceivedAt = transferReceivedAt
expectedResponse.customers =
Customers(StellarId(CUSTOMER_ID, null), StellarId(CUSTOMER_ID, null))

Expand Down

0 comments on commit 58b98ee

Please sign in to comment.