Just to follow up, I figured this out. In case it helps anyone else in the future:
The div I was waiting on is a loading mask that shows up while an async process is going on. Because I'm using "mock" JSON data during testing, the load happens very quickly. So even though I could SEE the mask appear and then disappear, it looks like it happened fast enough that Selenium never even caught it. I'm not sure what internal Selenium checks the DOM, but apparently things can slip though if they happen fast enough.
Once I realized this, I just created a helper function like:
protected void waitForLoadingMaskRemoved() {
SelenideElement existingMask = $$( "div.x-mask" ).find( visible )
if( existingMask.exists() ) {
existingMask.waitUntil( disappears, 5000 )
}
}
So that IF a visible mask is found, it waits for it to be hidden. Otherwise, things just keep going. This seems to work perfectly.
Regards,
Brian