Fix a test that was failing intermittently