-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: surface sdk versions from version.swift #23
Conversation
@@ -1 +1,2 @@ | |||
let Primer3DSVersion = "2.0.0" | |||
let Primer3DSSDKVersion = "2.0.0" | |||
let NetceteraSDKVersion = "2.3.74" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@NQuinn27 can you please check if ThreeDS2ServiceSDK
has a function to get the version?Their Android SDK offers that
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From what I can see, the only way to get to it is via the info.plist
of the ThreeDS_SDK
Framework. This is how we were fetching it before, and it appears like it wasn't working correctly in some merchants setups.
I feel ok about hardcoding it here, I added a unit test to flag when it is out of sync with the version in the info.plist
- so we wont release a wrong version number here.
XCTAssertEqual(VersionUtils.threeDSSDKVersionNumber, NetceteraSDKVersion) | ||
} | ||
|
||
func test_3DSMatchesNetcetera() throws { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@semirp The test I refrerenced in my last comment. This Bundle(for: ThreeDS2ServiceSDK.self)
is the correct way to get the version - and should work in a normal integration (so it works for us to test the versions match) - but doesnt work in certain merchants setups.
I think this gives us the certainty we need that the version will be correct in the wild, and the checks that we dont forget to update it.
hardcodedVersion
to be removed later.