Fixed a non-deterministic test; refs #23099.