Skip to content
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

Stop using keychain in integration tests #391

Merged

Conversation

julianlocke
Copy link
Contributor

@julianlocke julianlocke commented Dec 12, 2023

This PR:

  • Removes all use of Keychain in integration tests by replacing Keychain with an in-memory fake.
  • Finishes the implementation of the TeamClient setup used in some objc compatibility layer tests.
  • Fixes an occasional flake where swift and objc calls to groupsUpdate would collide on a group name. The group was always previously deleted, but trying to recreate it immediately could problematically occur before some cleanup or state propagation.
  • Fixes a typo

@julianlocke julianlocke changed the title Test stop using keychain in integration tests Stop using keychain in integration tests Dec 12, 2023
@julianlocke julianlocke requested a review from jaquish December 13, 2023 00:04
@julianlocke julianlocke force-pushed the test-stop-using-keychain-in-integration-tests branch from acc091c to bacab8a Compare December 13, 2023 23:50
@@ -144,3 +144,37 @@ public class SecureStorageAccesDefaultImpl: SecureStorageAccess {
}
}
}

public class SecureStorageAccessTestImpl: SecureStorageAccess {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this live next to test code?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fair point, let me poke at this


/// Only for use in tests. Resets DropboxOAuthManager so a new one for Team client use can be set up.
@objc
public static func __test_only_resetForTeamSetup() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here- shouldn't this live in /TestSwiftyDropbox?

@julianlocke julianlocke merged commit 736a21a into branch_10.0.0-beta Dec 14, 2023
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants