|
@@ -4,7 +4,6 @@ import static com.provectus.kafka.ui.pages.ksqldb.enums.KsqlMenuTabs.STREAMS;
|
|
import static com.provectus.kafka.ui.pages.ksqldb.enums.KsqlQueryConfig.SELECT_ALL_FROM;
|
|
import static com.provectus.kafka.ui.pages.ksqldb.enums.KsqlQueryConfig.SELECT_ALL_FROM;
|
|
import static com.provectus.kafka.ui.pages.ksqldb.enums.KsqlQueryConfig.SHOW_STREAMS;
|
|
import static com.provectus.kafka.ui.pages.ksqldb.enums.KsqlQueryConfig.SHOW_STREAMS;
|
|
import static com.provectus.kafka.ui.pages.ksqldb.enums.KsqlQueryConfig.SHOW_TABLES;
|
|
import static com.provectus.kafka.ui.pages.ksqldb.enums.KsqlQueryConfig.SHOW_TABLES;
|
|
-import static com.provectus.kafka.ui.pages.panels.enums.MenuItem.KSQL_DB;
|
|
|
|
import static org.apache.commons.lang3.RandomStringUtils.randomAlphabetic;
|
|
import static org.apache.commons.lang3.RandomStringUtils.randomAlphabetic;
|
|
|
|
|
|
import com.provectus.kafka.ui.BaseTest;
|
|
import com.provectus.kafka.ui.BaseTest;
|
|
@@ -45,10 +44,7 @@ public class KsqlDbTest extends BaseTest {
|
|
@QaseId(284)
|
|
@QaseId(284)
|
|
@Test(priority = 1)
|
|
@Test(priority = 1)
|
|
public void streamsAndTablesVisibilityCheck() {
|
|
public void streamsAndTablesVisibilityCheck() {
|
|
- naviSideBar
|
|
|
|
- .openSideMenu(KSQL_DB);
|
|
|
|
- ksqlDbList
|
|
|
|
- .waitUntilScreenReady();
|
|
|
|
|
|
+ navigateToKsqlDb();
|
|
SoftAssert softly = new SoftAssert();
|
|
SoftAssert softly = new SoftAssert();
|
|
softly.assertTrue(ksqlDbList.getTableByName(FIRST_TABLE.getName()).isVisible(), "getTableByName()");
|
|
softly.assertTrue(ksqlDbList.getTableByName(FIRST_TABLE.getName()).isVisible(), "getTableByName()");
|
|
softly.assertTrue(ksqlDbList.getTableByName(SECOND_TABLE.getName()).isVisible(), "getTableByName()");
|
|
softly.assertTrue(ksqlDbList.getTableByName(SECOND_TABLE.getName()).isVisible(), "getTableByName()");
|
|
@@ -69,8 +65,24 @@ public class KsqlDbTest extends BaseTest {
|
|
Assert.assertTrue(ksqlQueryForm.getEnteredQuery().isEmpty(), "getEnteredQuery()");
|
|
Assert.assertTrue(ksqlQueryForm.getEnteredQuery().isEmpty(), "getEnteredQuery()");
|
|
}
|
|
}
|
|
|
|
|
|
- @QaseId(41)
|
|
|
|
|
|
+ @QaseId(344)
|
|
@Test(priority = 3)
|
|
@Test(priority = 3)
|
|
|
|
+ public void clearResultsButtonCheck() {
|
|
|
|
+ String notValidQuery = "some not valid request";
|
|
|
|
+ navigateToKsqlDb();
|
|
|
|
+ ksqlDbList
|
|
|
|
+ .clickExecuteKsqlRequestBtn();
|
|
|
|
+ ksqlQueryForm
|
|
|
|
+ .waitUntilScreenReady()
|
|
|
|
+ .setQuery(notValidQuery);
|
|
|
|
+ Assert.assertFalse(ksqlQueryForm.isClearResultsBtnEnabled(), "isClearResultsBtnEnabled()");
|
|
|
|
+ ksqlQueryForm
|
|
|
|
+ .clickExecuteBtn(notValidQuery);
|
|
|
|
+ Assert.assertFalse(ksqlQueryForm.isClearResultsBtnEnabled(), "isClearResultsBtnEnabled()");
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ @QaseId(41)
|
|
|
|
+ @Test(priority = 4)
|
|
public void checkShowTablesRequestExecution() {
|
|
public void checkShowTablesRequestExecution() {
|
|
navigateToKsqlDbAndExecuteRequest(SHOW_TABLES.getQuery());
|
|
navigateToKsqlDbAndExecuteRequest(SHOW_TABLES.getQuery());
|
|
SoftAssert softly = new SoftAssert();
|
|
SoftAssert softly = new SoftAssert();
|
|
@@ -83,7 +95,7 @@ public class KsqlDbTest extends BaseTest {
|
|
}
|
|
}
|
|
|
|
|
|
@QaseId(278)
|
|
@QaseId(278)
|
|
- @Test(priority = 4)
|
|
|
|
|
|
+ @Test(priority = 5)
|
|
public void checkShowStreamsRequestExecution() {
|
|
public void checkShowStreamsRequestExecution() {
|
|
navigateToKsqlDbAndExecuteRequest(SHOW_STREAMS.getQuery());
|
|
navigateToKsqlDbAndExecuteRequest(SHOW_STREAMS.getQuery());
|
|
SoftAssert softly = new SoftAssert();
|
|
SoftAssert softly = new SoftAssert();
|
|
@@ -94,7 +106,7 @@ public class KsqlDbTest extends BaseTest {
|
|
}
|
|
}
|
|
|
|
|
|
@QaseId(86)
|
|
@QaseId(86)
|
|
- @Test(priority = 5)
|
|
|
|
|
|
+ @Test(priority = 6)
|
|
public void clearResultsForExecutedRequest() {
|
|
public void clearResultsForExecutedRequest() {
|
|
navigateToKsqlDbAndExecuteRequest(SHOW_TABLES.getQuery());
|
|
navigateToKsqlDbAndExecuteRequest(SHOW_TABLES.getQuery());
|
|
SoftAssert softly = new SoftAssert();
|
|
SoftAssert softly = new SoftAssert();
|
|
@@ -107,7 +119,7 @@ public class KsqlDbTest extends BaseTest {
|
|
}
|
|
}
|
|
|
|
|
|
@QaseId(277)
|
|
@QaseId(277)
|
|
- @Test(priority = 6)
|
|
|
|
|
|
+ @Test(priority = 7)
|
|
public void stopQueryFunctionalCheck() {
|
|
public void stopQueryFunctionalCheck() {
|
|
navigateToKsqlDbAndExecuteRequest(String.format(SELECT_ALL_FROM.getQuery(), FIRST_TABLE.getName()));
|
|
navigateToKsqlDbAndExecuteRequest(String.format(SELECT_ALL_FROM.getQuery(), FIRST_TABLE.getName()));
|
|
Assert.assertTrue(ksqlQueryForm.isAbortBtnVisible(), "isAbortBtnVisible()");
|
|
Assert.assertTrue(ksqlQueryForm.isAbortBtnVisible(), "isAbortBtnVisible()");
|
|
@@ -123,10 +135,8 @@ public class KsqlDbTest extends BaseTest {
|
|
|
|
|
|
@Step
|
|
@Step
|
|
private void navigateToKsqlDbAndExecuteRequest(String query) {
|
|
private void navigateToKsqlDbAndExecuteRequest(String query) {
|
|
- naviSideBar
|
|
|
|
- .openSideMenu(KSQL_DB);
|
|
|
|
|
|
+ navigateToKsqlDb();
|
|
ksqlDbList
|
|
ksqlDbList
|
|
- .waitUntilScreenReady()
|
|
|
|
.clickExecuteKsqlRequestBtn();
|
|
.clickExecuteKsqlRequestBtn();
|
|
ksqlQueryForm
|
|
ksqlQueryForm
|
|
.waitUntilScreenReady()
|
|
.waitUntilScreenReady()
|