Add basic tests for unit formatting

There is an issue with mixed literal/macro input: to be fixed shortly.