Improve test base classes