Improved test utilities for config cache invalidation