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
Dialog util #28
Dialog util #28
Conversation
btkelly
commented
Feb 1, 2016
- Added dialog util that can be used to easily show dialogs related to the bootstrap check.
- Added a simple logging class that still needs the LogLevel connected and set from the Gandalf installer.
- Added the ability to set the package name from the Gandalf installer
PMD Reporter Violations:Violation: UseUtilityClass Checkstyle Reporter Violations:Violation: com.puppycrawl.tools.checkstyle.checks.sizes.LineLengthCheck Violation: com.puppycrawl.tools.checkstyle.checks.design.HideUtilityClassConstructorCheck |
Congrats! No 💩 code found, this PR is safe to merge. |
Does this PR aim to completely resolve #6? |
protected void onStop() { | ||
super.onStop(); | ||
MockWebServerUtil.setMockBootstrapRes(this, R.raw.no_action_bootstrap); | ||
System.exit(0); |
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.
What's going on here? What's the effect of this call?
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.
This is to fix the issue where you are stuck with the force update call as you are always blocked when trying to get into the app. This allows you to see each scenario once and on restart it will revert back to no action where you can again select which one to simulate.
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.
Ah, smart! Might be worth throwing a comment in here with that^ explanation.
I would say yes, but as you can see in the code I changed it a bit from my original requirement of it being dumb. Seemed like a better interaction to have it save the user responses and react to clicks. |
@@ -65,7 +67,7 @@ public void run() { | |||
MockResponse mockResponse = new MockResponse(); | |||
mockResponse.setResponseCode(200); | |||
mockResponse.setBody(mockBootstrapJsonBody); | |||
mockResponse.setBodyDelay(4, TimeUnit.SECONDS); | |||
mockResponse.setBodyDelay(2, TimeUnit.SECONDS); |
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.
What factors influence a good choice for this number?
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.
Nothing really, I just wanted to show that what could be done like a progress spinner while the call is loading. 4 seemed too long while I was testing, got sick of waiting.
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.
Ah, makes sense!
Congrats! No 💩 code found, this PR is safe to merge. |