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

fix: reinstall ios app to clear state reliably #2118

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

axelniklasson
Copy link
Collaborator

@axelniklasson axelniklasson commented Oct 30, 2024

Proposed changes

Reinstall the app and then launch it instead of manually trying to delete app state folders, which should improve the experience when relying on clear state to have a completely blank slate in the app.

Relates to #1601

@axelniklasson axelniklasson marked this pull request as ready for review October 30, 2024 15:06
@herval
Copy link
Collaborator

herval commented Oct 30, 2024

how do we make sure this is working?

Comment on lines +253 to +255
launch(deviceId, bundleId, emptyList(), null)

ensureRunning(deviceId, bundleId)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
launch(deviceId, bundleId, emptyList(), null)
ensureRunning(deviceId, bundleId)

I tested this without launching the app locally, and it works as expected.

Reasoning:
clear state can be used either as a standalone command (- clearState) or as part of the - launchApp command. In the former case, we don't want to launch the app because it's not specified by the command. In the latter case, the app will be launched automatically after clearState, so there's no need to relaunch it.

WDYT?

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.

3 participants