Fix flaky shouldNotSnapshotPopulatingIndexes

The test was racing with the population job that was started, because was
initially in a populating state.

The changes introduce a latch, that prevent this population job from completing
before we have taking our snapshot, thus ensuring that the index is indeed
still populating when we take our snapshot.
Merge pull request #1372 from chrisvest/fix-flaky-shouldNotSnapshotPopulatingIndexes

Fix flaky shouldNotSnapshotPopulatingIndexes