Improve test reliability