mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-03-22 06:50:54 +07:00
[rdct-tests] handleCheckBoxWithFileName: minor polishes
GitOrigin-RevId: 448431b71c7586360bbd1e0a4aefc18aed4ac441
This commit is contained in:
committed by
intellij-monorepo-bot
parent
9c88d9696a
commit
53caa81e0e
@@ -23,16 +23,16 @@ class JChangesListViewFixture(private val robot: Robot, private val component: J
|
||||
|
||||
private fun handleCheckBoxWithFileName(fileName: String, setEnabled: Boolean) {
|
||||
val root = component.model.root as DefaultMutableTreeNode
|
||||
val node = TreeUtil.findNode(root) { it.toString().contains(fileName) }
|
||||
val node = TreeUtil.findNode(root) { it.toString().contains(fileName) } ?: error("Node with name containing $fileName is not found")
|
||||
|
||||
val fileTreePath = TreePath(node!!.path)
|
||||
val fileTreePath = TreePath(node.path)
|
||||
val checkbox = getCheckBoxForNode(node, fileTreePath)
|
||||
|
||||
if (checkbox.isSelected != setEnabled) {
|
||||
val fileTrePathLocation = computeOnEdt {
|
||||
val fileTreePathLocation = computeOnEdt {
|
||||
component.getPathBounds(fileTreePath) ?: error("Have not found bounds")
|
||||
}
|
||||
clickOnCheckbox(checkbox, fileTrePathLocation)
|
||||
clickOnCheckbox(checkbox, fileTreePathLocation)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user