Skip to content
This repository has been archived by the owner before Nov 9, 2022. It is now read-only.

Implement comprehensive unit tests #552

9 tasks done
yaronyg opened this issue Feb 19, 2016 · 1 comment
9 tasks done

Implement comprehensive unit tests #552

yaronyg opened this issue Feb 19, 2016 · 1 comment


Copy link

yaronyg commented Feb 19, 2016

Our current CI based testing for our native code is non-existent. We have a few ad-hoc tests for iOS and even fewer for Android. Right now isn't the time to put in a full native test environment into CI (although I've added that to the back log). But we depend on this code to work and so our substitute will be to define comprehensive thaliMobileNative tests to really put the code through its paces.

We need to test things like

  • Making the thaliMobile tests actually use PSK, right now they don't because we don't pass in a psk function. See the tests in testThaliMobileNativeWrapper and testThaliWifiInfrastructure for examples of how to configure things.
  • honoring the logic around connection loss (e.g. any time either end of a native connection is lost we have to make sure that everything is torn down).
    • I'm doing some very basic testing on connection loss but more thorough testing is called for, take a look when I check it in and decide what you think
  • We have to make sure to do most of the testing using the coordination server since every test needs to run across at least two iOS devices in both directions to make sure we cover all the fun issues around bigger vs smaller peerIDs.
    • This is the main area I'll be focusing on. My plan is to write tests both at the thaliMobileNative and thaliMobileNativeWrapper layers.
  • We also need tests that show that we can successfully sync data with multiple devices simultaneously.
  • We also need to more aggressively test our ability to start/stop/start/stop with connections in between.
  • We need tests that intentionally kill and then recreate connections to show that the stack can handle it
  • We need tests that use kill connection and make sure we can successfully recover
  • Put in a test for Android where we are advertising and not listening on one end and the inverse at the other so we can test if the Bluetooth handshake will work.
  • We need a test to make sure that if we haven't called one of the start methods (e.g. advertising or listening) then we don't publish any peer availability changed events.
@yaronyg yaronyg self-assigned this Feb 19, 2016
@yaronyg yaronyg added this to the New Infra milestone Feb 19, 2016
@yaronyg yaronyg assigned vjrantal and unassigned yaronyg Feb 22, 2016
@vjrantal vjrantal changed the title Define comprehensive thaliMobileNative tests Define comprehensive unit tests Mar 23, 2016
@vjrantal vjrantal changed the title Define comprehensive unit tests Implement comprehensive unit tests Mar 23, 2016
@vjrantal vjrantal assigned yaronyg and unassigned vjrantal Mar 30, 2016
@yaronyg yaronyg removed their assignment Jul 15, 2016
Copy link
Member Author

yaronyg commented Sep 26, 2016


@yaronyg yaronyg closed this as completed Sep 26, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
None yet
None yet

No branches or pull requests

2 participants