Add more doc and unit tests for units.