Fix some tests

This is a first pass at fixing the tests.