Add unit tests and Makefile.