Search in sources :

Example 11 with Form

use of io.syndesis.qe.fragments.common.form.Form in project syndesis-qe by syndesisio.

the class ApicurioSteps method checkFieldsExistence.

@Then("^check that apicurio connection authentication type contains only fields:$")
public void checkFieldsExistence(DataTable fields) {
    List<List<String>> dataRows = fields.cells();
    List<String> first = new ArrayList<String>();
    for (List<String> row : dataRows) {
        first.add(row.get(0));
    }
    new Form($(Elements.CARD_PF)).checkByTestId(first);
}
Also used : Form(io.syndesis.qe.fragments.common.form.Form) ArrayList(java.util.ArrayList) ArrayList(java.util.ArrayList) List(java.util.List) Then(io.cucumber.java.en.Then)

Example 12 with Form

use of io.syndesis.qe.fragments.common.form.Form in project syndesis-qe by syndesisio.

the class ReadMessages method selectChannel.

public void selectChannel(String channel) {
    // check that value of the channel is in the option data list
    SelenideElement dataList = $(By.id("channel"));
    dataList.findAll(By.tagName("option")).filter(Condition.value(channel)).shouldHaveSize(1);
    // the name of the channel has to be fill in manually. The select from the option in the <datalist> is not able
    Map<String, String> mymap = new HashMap<String, String>();
    mymap.put("channel", channel);
    new Form(new SyndesisRootPage().getRootElement()).fillByTestId(mymap);
}
Also used : SyndesisRootPage(io.syndesis.qe.pages.SyndesisRootPage) HashMap(java.util.HashMap) Form(io.syndesis.qe.fragments.common.form.Form) SelenideElement(com.codeborne.selenide.SelenideElement)

Example 13 with Form

use of io.syndesis.qe.fragments.common.form.Form in project syndesis-qe by syndesisio.

the class ServiceNowSteps method fillInAndModifyValuesByElementID.

@When("fill in and modify values by element ID")
public void fillInAndModifyValuesByElementID(DataTable data) {
    Map<String, String> map = new HashMap<>();
    data.asMap(String.class, String.class).forEach((k, v) -> map.put(k.toString(), snUtils.modifySNNumber(v.toString())));
    new Form(new SyndesisRootPage().getRootElement()).fillByTestId(map);
}
Also used : SyndesisRootPage(io.syndesis.qe.pages.SyndesisRootPage) HashMap(java.util.HashMap) Form(io.syndesis.qe.fragments.common.form.Form) When(io.cucumber.java.en.When)

Example 14 with Form

use of io.syndesis.qe.fragments.common.form.Form in project syndesis-qe by syndesisio.

the class CreateIntegrationSteps method fillNameConnectionForm.

@When("^fills? Name Integration form$")
public void fillNameConnectionForm(DataTable data) {
    new Form(createIntegration.getRootElement()).fillByTestId(data.asMap(String.class, String.class));
    TestUtils.sleepForJenkinsDelayIfHigher(1);
}
Also used : Form(io.syndesis.qe.fragments.common.form.Form) When(io.cucumber.java.en.When)

Aggregations

Form (io.syndesis.qe.fragments.common.form.Form)14 SyndesisRootPage (io.syndesis.qe.pages.SyndesisRootPage)8 When (io.cucumber.java.en.When)6 HashMap (java.util.HashMap)6 Then (io.cucumber.java.en.Then)5 SelenideElement (com.codeborne.selenide.SelenideElement)2 Account (io.syndesis.qe.account.Account)2 GoogleAccount (io.syndesis.qe.utils.google.GoogleAccount)1 ArrayList (java.util.ArrayList)1 List (java.util.List)1