-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
MBL-1161: Add code to handle storing/retrieving/deleting Keychain items #1944
Merged
amy-at-kickstarter
merged 2 commits into
main
from
feat/adyer/MBL-1161/add-keychain-code
Feb 14, 2024
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -47,6 +47,16 @@ | |
ReferencedContainer = "container:Kickstarter.xcodeproj"> | ||
</BuildableReference> | ||
</TestableReference> | ||
<TestableReference | ||
skipped = "NO"> | ||
<BuildableReference | ||
BuildableIdentifier = "primary" | ||
BlueprintIdentifier = "E113BD802B7D255000D3A809" | ||
BuildableName = "Library-Keychain-iOSTests.xctest" | ||
BlueprintName = "Library-Keychain-iOSTests" | ||
ReferencedContainer = "container:Kickstarter.xcodeproj"> | ||
</BuildableReference> | ||
</TestableReference> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
</Testables> | ||
</TestAction> | ||
<LaunchAction | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import XCTest | ||
|
||
final class Library_Keychain_iOSTests: XCTestCase { | ||
func testLibraryKeychainExists() { | ||
XCTAssertTrue(true) | ||
|
||
/* | ||
This testing bundle, Library-Keychain-iOSTests, exists so that we can run KeychainTests. | ||
|
||
Testing the keychain requires the unit tests to be hosted; otherwise it throws errors | ||
about missing entitlements. | ||
|
||
However, the rest of our library tests require the unit tests NOT to be hosted. | ||
This target is just split out so we can run KeychainTests.swift in that hosted environment.. | ||
|
||
*/ | ||
} | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
OK, to get these tests to work, I had to make a new testing bundle, which is hosted, which just contains a single test,
KeychainTests
. Using an app host forLibrary-iOSTests
breaks several tests, but without using the app host,KeychainTests
will fail.These changes look like this in the GUI:
![Screenshot 2024-02-14 at 11 53 14 AM](https://private-user-images.githubusercontent.com/146007185/304814760-b66cfc1b-e461-404f-80d1-db89c49c49d3.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyMjcwNTcsIm5iZiI6MTczOTIyNjc1NywicGF0aCI6Ii8xNDYwMDcxODUvMzA0ODE0NzYwLWI2NmNmYzFiLWU0NjEtNDA0Zi04MGQxLWRiODljNDljNDlkMy5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC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