LPS-51280 Make test more robust