Add some basic testing infrastructure and tests