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

Support Strict Concurrency for SnapshotHelper #21400

Merged
merged 1 commit into from Oct 6, 2023

Conversation

giginet
Copy link
Collaborator

@giginet giginet commented Jul 16, 2023

Checklist

  • I've run bundle exec rspec from the root directory to see all new and existing tests pass
  • I've followed the fastlane code style and run bundle exec rubocop -a to ensure the code style is valid
  • I see several green ci/circleci builds in the "All checks have passed" section of my PR (connect CircleCI to GitHub if not)
  • I've read the Contribution Guidelines
  • I've updated the documentation if necessary.

Motivation and Context

When enabling Strict Concurrency to Complete, SnapshotHelper raises some warnings.

Screenshot 2023-07-16 at 17 58 56

This PR makes to update SnapshotHelper to suppress warnings.

Description

All implementations of SnapshotHelper should be worked on @MainActor.

Testing Steps

  1. Make project
  2. bundle exec fastlane snapshot init
  3. Set Strict Concurrency to Complete
  4. bundle exec snapshot run

@giginet giginet self-assigned this Jul 16, 2023
open class Snapshot: NSObject {
static var app: XCUIApplication?
static var waitForAnimations = true
static var cacheDirectory: URL?
static var screenshotsDirectory: URL? {
return cacheDirectory?.appendingPathComponent("screenshots", isDirectory: true)
}
static var deviceLanguage = ""
static var currentLocale = ""
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It should be renamed to avoid conflicting setLocale implemented in this file between auto-generated by @objcMembers

Copy link
Collaborator

@getaaron getaaron left a comment

Choose a reason for hiding this comment

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

LGTM

@giginet giginet merged commit 8cbb420 into fastlane:master Oct 6, 2023
8 checks passed
@giginet giginet deleted the snapshot-concurrency-support branch October 6, 2023 05:01
@giginet
Copy link
Collaborator Author

giginet commented Oct 6, 2023

@getaaron Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants