Various test fixes