Adding more tests and fixing bugs they expose

Making sure all post build steps always run.