Real time clock unit tests.

Improve the unit test message checking functions.

Add a flush call to flush all outstanding messages on the A stream.

Make the RTC code detect partial time & date sets and optimise things a little.
Flush the communication stream after setting the RTC time.  The seconds are fairly critical.
Add support for the flush operation and test that it is actually called.