Skip to content

Commit

Permalink
Clean up old tests where we check the message for analytics events
Browse files Browse the repository at this point in the history
COAND-1010
  • Loading branch information
araratthehero committed Dec 11, 2024
1 parent f36ca33 commit 1386c37
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -623,10 +623,10 @@ internal class DefaultAdyen3DS2Delegate(
}

private fun trackFingerprintActionEvent(action: Action) =
trackActionEvent(action, ANALYTICS_MESSAGE_FINGERPRINT)
trackActionEvent(action, "Fingerprint action was handled by the SDK")

private fun trackChallengeActionEvent(action: Action) =
trackActionEvent(action, ANALYTICS_MESSAGE_CHALLENGE)
trackActionEvent(action, "Challenge action was handled by the SDK")

private fun trackActionEvent(action: Action, message: String) {
val event = GenericEvents.action(
Expand Down Expand Up @@ -740,13 +740,6 @@ internal class DefaultAdyen3DS2Delegate(
}

companion object {
@VisibleForTesting
internal const val ANALYTICS_MESSAGE_FINGERPRINT =
"Fingerprint action was handled by the SDK"

@VisibleForTesting
internal const val ANALYTICS_MESSAGE_CHALLENGE = "Challenge action was handled by the SDK"

private const val DEFAULT_CHALLENGE_TIME_OUT = 10
private const val PROTOCOL_VERSION_2_1_0 = "2.1.0"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -548,7 +548,6 @@ internal class DefaultAdyen3DS2DelegateTest(
val expectedEvent = GenericEvents.action(
component = TEST_PAYMENT_METHOD_TYPE,
subType = TEST_ACTION_TYPE,
message = DefaultAdyen3DS2Delegate.ANALYTICS_MESSAGE_FINGERPRINT,
)
analyticsManager.assertHasEventEquals(expectedEvent)
}
Expand All @@ -567,7 +566,6 @@ internal class DefaultAdyen3DS2DelegateTest(
val expectedEvent = GenericEvents.action(
component = TEST_PAYMENT_METHOD_TYPE,
subType = TEST_ACTION_TYPE,
message = DefaultAdyen3DS2Delegate.ANALYTICS_MESSAGE_CHALLENGE,
)
analyticsManager.assertHasEventEquals(expectedEvent)
}
Expand All @@ -587,7 +585,6 @@ internal class DefaultAdyen3DS2DelegateTest(
val expectedEvent = GenericEvents.action(
component = TEST_PAYMENT_METHOD_TYPE,
subType = TEST_ACTION_TYPE,
message = DefaultAdyen3DS2Delegate.ANALYTICS_MESSAGE_FINGERPRINT,
)
analyticsManager.assertHasEventEquals(expectedEvent)
}
Expand All @@ -607,7 +604,6 @@ internal class DefaultAdyen3DS2DelegateTest(
val expectedEvent = GenericEvents.action(
component = TEST_PAYMENT_METHOD_TYPE,
subType = TEST_ACTION_TYPE,
message = DefaultAdyen3DS2Delegate.ANALYTICS_MESSAGE_CHALLENGE,
)
analyticsManager.assertHasEventEquals(expectedEvent)
}
Expand Down

0 comments on commit 1386c37

Please sign in to comment.