Restructure tests, update Makefile