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

feat(android-setup): Fix adbLocation-related problems #2900

Merged
merged 2 commits into from
Jun 17, 2020
Merged

feat(android-setup): Fix adbLocation-related problems #2900

merged 2 commits into from
Jun 17, 2020

Conversation

DaveTryon
Copy link
Contributor

Description of changes

When we put the dialogs all together, we found that things only worked if you specified adbLocation via the environment variables. This was partly because the step machine had a path that allowed execution without having a validated ADB location, and partly due to a bug in how I was passing the adbLocation through the internal layers.

Pull request checklist

  • [n/a] Addresses an existing issue: #0000
  • Ran yarn fastpass
  • Added/updated relevant unit test(s) (and ran yarn test)
  • Verified code coverage for the changes made. Check coverage report at: <rootDir>/test-results/unit/coverage
  • PR title AND final merge commit title both start with a semantic tag (fix:, chore:, feat(feature-name):, refactor:). See CONTRIBUTING.md.
  • [n/a] (UI changes only) Added screenshots/GIFs to description above
  • [n/a] (UI changes only) Verified usability with NVDA/JAWS

@DaveTryon DaveTryon requested a review from dbjorge June 17, 2020 17:35
@DaveTryon DaveTryon requested a review from a team as a code owner June 17, 2020 17:35
@@ -8,7 +8,7 @@ export const promptLocateAdb: AndroidSetupStepConfig = deps => {
actions: {
saveAdbPath: (path: string) => {
deps.setAdbPath(path);
deps.stepTransition('prompt-connect-to-device');
deps.stepTransition('detect-adb');
Copy link
Contributor Author

@DaveTryon DaveTryon Jun 17, 2020

Choose a reason for hiding this comment

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

The steps must successfully go through the detect-adb step before progressing to anything that needs ADB. This path was allowing us to try to prompt for devices without a validated ADB

export const createActionMock = <Payload>(
payload: Payload,
scope: string = null,
): IMock<Action<Payload>> => {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This allows us to mock the invocation with the specified scope

@DaveTryon DaveTryon merged commit b7398db into microsoft:master Jun 17, 2020
@DaveTryon DaveTryon deleted the FixAdbLocation branch June 17, 2020 18:48
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