From 4bf6f8ed8137a471b73bbb557dcbe7c94ecbdbb5 Mon Sep 17 00:00:00 2001 From: Sergey Karashevich Date: Tue, 21 Nov 2017 17:01:43 +0300 Subject: [PATCH] [gui-test] extend evaluateLicense step on the FirstStart --- .../src/com/intellij/testGuiFramework/impl/FirstStart.kt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/platform/testGuiFramework/src/com/intellij/testGuiFramework/impl/FirstStart.kt b/platform/testGuiFramework/src/com/intellij/testGuiFramework/impl/FirstStart.kt index 5c4f3d2a7e26..ecf5cdf3d7bd 100644 --- a/platform/testGuiFramework/src/com/intellij/testGuiFramework/impl/FirstStart.kt +++ b/platform/testGuiFramework/src/com/intellij/testGuiFramework/impl/FirstStart.kt @@ -208,6 +208,14 @@ abstract class FirstStart(val ideType: IdeType) { return JDialogFixture(this, jDialog) } + fun Robot.dialog(timeoutSeconds: Long = DEFAULT_TIMEOUT, titleMatcher: (String) -> Boolean): JDialogFixture { + val jDialog = waitUntilFound(this, null, JDialog::class.java, timeoutSeconds) { dialog -> + titleMatcher(dialog.title) + } + return JDialogFixture(this, jDialog) + } + + fun Robot.radioButton(text: String, timeoutSeconds: Long = DEFAULT_TIMEOUT): JRadioButtonFixture { val jRadioButton = waitUntilFound(this, null, JRadioButton::class.java, timeoutSeconds) { radioButton -> radioButton.text == text && radioButton.isShowing && radioButton.isEnabled