adafruit / Adafruit_Mynewt

Apache Mynewt documentation and test project for the nRF5x family of BLE SoCs
MIT License
8 stars 3 forks source link

Implement a unit test package for the Feather52 #13

Closed microbuilder closed 8 years ago

microbuilder commented 8 years ago

One of the nicer features of Mynewt is the built in unit test framework, as well as HW simulation (although this doesn't yet take into account the BLE stack).

A simple test suite should be implemented to get familiar with the testutil library, as described here: http://mynewt.apache.org/os/tutorials/unit_test/

We can extend this later to proper production tests that can be used to verify the hardware coming off the production line.

microbuilder commented 8 years ago

Notes on creating and running tests should be added to https://github.com/adafruit/Adafruit_Mynewt/blob/master/docs/12_UnitTests.md

microbuilder commented 8 years ago

An initial test can be to make sure the config settings in #8 are properly restored after a factory reset, and that the values can be updated in code.

hathach commented 8 years ago

that is nice, it is a PITA to set these up previously :D

microbuilder commented 8 years ago

Believe me I remember :) This is why i like Mynewt so much ... they've thought of all the important details for real world deployments and made them as easy as possible (for an embedded project anyway).

microbuilder commented 8 years ago

The new FIFO module is a good place to test this out since it can easily run on a simulator (BLE doesn't have simulator support yet), and it's an important component worth fully testing anyway.

microbuilder commented 8 years ago

Add documentation on creating and running unit tests here: https://github.com/adafruit/Adafruit_Mynewt/blob/master/docs/12_UnitTests.md

Implemented the basic plumbing for FIFO tests via cb44c18868b66a07d5d8ce4b3d40233da4e3dee4, tested natively on OS X

microbuilder commented 8 years ago

Closing this for now since the skeleton code is there, but the old FIFO tests should be added to the mynewt repo as a minimum.

microbuilder commented 8 years ago

Perfect, thanks.