This repository has been archived by the owner on Jun 19, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 223
Add first batch unit tests #55
Open
smoy
wants to merge
22
commits into
xamarin:master
Choose a base branch
from
smoy:add_first_batch_unit_tests
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
When one wants to connect multiple BLE devices, the singleton approach doesn't work well. In addition, the adapter class member inside GattCallback is not being used, it is deleted as well. The access modifier of _gatt and _gattcallback inside Device is changed from protected to internal. Such that, the Adapter instance can update those fields upon connection attempt.
* Eliminte the need to create new device instance * Wire up RSSI to the device * Get DeviceState from the profileState given by GattCallback
we can remove them when the method finishes its work. Prior to the change, upon re-entry of ServiceList, the services entry are added more once because we did not remove previous added delegate.
… in interest. * Robustify removing delegates upon device disconnection
* During attempt to connect, if an device already has a Gatt instance, tear it down before trying to connect. * During attempt to disconnect, tear down the gatt instance to free all the android resources
…evice instance instead. * This is in preparation to allow read/write of characteristic to check if a device is disconnected before attempting those read/write actions.
* Minimize the number of new Device instance that is constructed * Delay Service discovered event registation until Discover service is called * Remove DiscoveredService handler once we receive the callback from OnDiscoveredService
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I have a fork of Monkey.Robotics and finally start adding some tests on the API. This maybe helpful for others who want to tinkle with the project and need regression testing.