@com.thoughtworks.gauge.Step( "Verify that material <materialName> cannot be deleted because of reason <message>") public void verifyThatMaterialCannotBeDeletedBecauseOfReason(String materialName, String message) throws Exception { ElementStub deleteIcon = deleteIconWithClass(materialName, "delete_icon_disabled"); Assert.assertThat(deleteIcon.exists(), Is.is(true)); Assert.assertThat(deleteIcon.fetch("title"), Is.is(message)); }
@com.thoughtworks.gauge.Step( "Verify that package with name <materialName> is added with url <url>") public void verifyThatPackageWithNameIsAddedWithUrl(String materialName, String url) throws Exception { ElementStub materialLink = browser.link(materialName); ElementStub materialRow = materialLink.parentNode().parentNode(); ElementStub materialTypeCell = browser.cell("Package").in(materialRow); Assert.assertThat(materialLink.exists(), Is.is(true)); Assert.assertThat(materialRow.containsText(scenarioState.expand(url)), Is.is(true)); Assert.assertThat(materialTypeCell.exists(), Is.is(true)); }
@com.thoughtworks.gauge.Step("Verify pipeline name is <pipelineName>") public void verifyPipelineNameIs(String pipelineName) throws Exception { Assert.assertThat( browser.link("selected").in(browser.listItem("collapsable lastCollapsable")).getText(), Is.is(scenarioState.pipelineNamed(pipelineName))); }
@com.thoughtworks.gauge.Step("Verify that material <materialName> can be deleted") public void verifyThatMaterialCanBeDeleted(String materialName) throws Exception { ElementStub deleteIcon = deleteIconWithClass(materialName, "icon_remove"); Assert.assertThat(deleteIcon.exists(), Is.is(true)); Assert.assertThat(deleteIcon.fetch("title"), Is.is("Remove this material")); }
@com.thoughtworks.gauge.Step("Verify that material with name <materialName> does not exist") public void verifyThatMaterialWithNameDoesNotExist(String materialName) throws Exception { ElementStub materialRow = getMaterialRowForMaterialName(materialName); Assert.assertThat(materialRow.exists(), Is.is(false)); }