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

Dedupe Tessels found on LAN connections. Fixes gh-719 #805

Merged
merged 1 commit into from
Jul 21, 2016

Conversation

rwaldron
Copy link
Contributor

@rwaldron rwaldron commented Jul 20, 2016

The problem here was:

  1. Nothing was actually being put into this.discovered
  2. Even if there had been, the test we did have would've passed anyway because it just put a number in the list and then emitted a number. That would assume that the thing put into this.discovered had the same object identity as the thing being checked, which is wrong.

Smoke Test

This is easier to do with 2 or more Tessels, so I've just taken screen shots to show the result of the changes:

Before:

After:

Signed-off-by: Rick Waldron waldron.rick@gmail.com

@rwaldron
Copy link
Contributor Author

@HipsterBrown @carlbaron

@HipsterBrown
Copy link
Contributor

The code looks good to me. Great addition to the tests as well. I can smoke test this tonight if needed. I appreciate the screenshots for previewing the issue and solution.

The problem here was:

1. Nothing was actually being put into `this.discovered`
2. Even if there had been, the test we did have would've passed anyway because it just put a number in the list and then emitted a number. That would assume that the thing put into `this.discovered` had the same object identity as the thing being checked, which is wrong.

Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
@HipsterBrown
Copy link
Contributor

Smoke test results:

Nicks-MacBook-Pro:tessel-test hipsterbrown$ t2 list
INFO Searching for nearby Tessels...
    USB j5
    USB tessel-router
    LAN j5
    LAN tessel-router
INFO Multiple Tessels found.
INFO Set default Tessel with environment variable (e.g. "export TESSEL=bulbasaur") or use the --name flag.
Nicks-MacBook-Pro:tessel-test hipsterbrown$

Tried it a couple times and always got the same result. 👍

@carlbaron
Copy link

Looks good to me. Have only 1 Tessel so couldn't easily smoke test it.

👍

@rwaldron
Copy link
Contributor Author

Again, I appreciate the reviews and smoke tests where possible :)

@rwaldron rwaldron merged commit 19686e4 into tessel:master Jul 21, 2016
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.

None yet

3 participants