[KTNB] Address a failing UI table test by waiting for indexes to be updated, as only after UI table components are updated

GitOrigin-RevId: 06374bb8cf22fd98a0bfc71046232b2e05f085a2
This commit is contained in:
Nikolay Egorov
2025-10-14 21:42:23 +00:00
committed by intellij-monorepo-bot
parent af20c4fb8a
commit d6e9b5efcd
@@ -29,6 +29,7 @@ import com.intellij.driver.sdk.ui.ui
import com.intellij.driver.sdk.wait
import com.intellij.driver.sdk.waitFor
import com.intellij.driver.sdk.waitForCodeAnalysis
import com.intellij.driver.sdk.waitForIndicators
import org.intellij.lang.annotations.Language
import kotlin.time.Duration
import kotlin.time.Duration.Companion.milliseconds
@@ -200,6 +201,16 @@ class NotebookEditorUiComponent(private val data: ComponentData) : JEditorUiComp
}
}
/**
* Combined action that runs all cells, wait for their execution, and waits for the indexes to update.
*/
fun runAllCellsAndWaitIndexesUpdated(timeout: Duration = 1.minutes, indicatorsTimeout: Duration = timeout): Unit = step("Executing cells and wait for indexes") {
runAllCellsAndWaitExecuted(timeout)
step("Waiting for indicators after execution") {
driver.waitForIndicators(indicatorsTimeout)
}
}
/*
This functions should be removed when fixed:
PY-84369