1
0
mirror of https://github.com/chylex/IntelliJ-IdeaVim.git synced 2025-02-23 05:46:04 +01:00

Update version of robot

This commit is contained in:
Alex Plate 2024-02-08 16:48:03 +02:00
parent 8c6f81aa00
commit d87965775a
No known key found for this signature in database
GPG Key ID: 0B97153C8FFEC09F
2 changed files with 2 additions and 20 deletions
gradle.properties
tests/ij-ui-tests/src/test/kotlin/ui

View File

@ -15,7 +15,7 @@ downloadIdeaSources=true
instrumentPluginCode=true
version=SNAPSHOT
javaVersion=17
remoteRobotVersion=0.11.21
remoteRobotVersion=0.11.22
antlrVersion=4.10.1

View File

@ -240,7 +240,7 @@ class UiTests {
step("Create $fileName file") {
with(projectViewTree) {
setExpandTimeout(30_000)
myExpand(projectName, "src")
expand(projectName, "src")
findText("src").click(MouseButton.RIGHT_BUTTON)
}
remoteRobot.actionMenu("New").click()
@ -249,24 +249,6 @@ class UiTests {
}
}
// This is a replacement of a standard `expand` function. The only change is that it has increased time in
// `blockingGet(30_000)`
// This should be replaced with a standard `expand` once the release with the following fix will be available:
// https://github.com/JetBrains/intellij-ui-test-robot/pull/392
private fun IdeaFrame.myExpand(vararg path: String) {
runJs(
"""
const expandingPathNodes = [${path.joinToString(",") { "\"${it}\"" }}]
const ignoreRoot = component.isRootVisible() === false
const treePath = com.intellij.ui.tree.TreePathUtil.convertArrayToTreePath(expandingPathNodes)
const toStringConverter = function(obj) {return java.util.Objects.toString(obj)}
const visitor = new com.intellij.ui.tree.TreeVisitor.ByTreePath(ignoreRoot, treePath, toStringConverter);
com.intellij.util.ui.tree.TreeUtil.promiseExpand(component, visitor).blockingGet(30_000)
"""
)
}
private fun IdeaFrame.reenableIdeaVim(editor: Editor) {
println("Run reenableIdeaVim...")
toggleIdeaVim()