As part of
SERVER-78505, new tests were added to check the behavior of the catalog cache while using the allowLocks option. However, in these tests, we are not blocking the progress of the refresh. This means that these tests have a race condition in which they will fail if the refresh happens fast enough that the new metadata is available.
We should block the refresh similar to this test which is also testing the allowLocks behavior.