unit tests for units.js