Tag: 宁静bdd

为什么我在Kotlin上运行这个特定的Cucumber步骤时发生ArrayIndexOutOfBoundsException?

我正在运行一个使用Java8和PicoContainer的Cucumber JVM功能文件。 我已经把这些步骤剥去了,所以它们是空的,而且我仍然遇到一个错误。 这是我的功能: Feature: Full Journey Scenario: Can load a typical JIRA csv and calculate the distribution from it Given a typical JIRA export "/closed_only_JIRA.csv" When I import it into Montecarluni Then I should see the distribution """ 6, 15, 3, 14, 2, 5, 6, 8, 5, 10, 15, 4, 2, 1 """ When […]

与Android的BDD与Kotlin

我正在考虑Android上的BDD测试方法。 示例应用程序 – 一个简单的使者 – 已经在Kotlin中完成,测试也是如此。 我结束了这样的事情: class IGotYourMessage : Scenario<LoginActivity>(LoginActivity::class.java, { Given() .iAmOnLoginScreen() .When() .iLogin() .Then() .iSeeContactsList() .iSeeAContact() .When() .iSelectAContact() .Then() .iSeeMessagesList() .iSeeAMessage() .With(hashMapOf( "email" to "john@doe.com", "password" to "foo", "contactFirstName" to "Jane", "contactLastName" to "Doe", "messageText" to "Hello John!" )) .With(hashMapOf( "email" to "jane@doe.com", "password" to "bar", "contactFirstName" to "John", "contactLastName" to "Doe", […]

我不能使用Kotlin的Serenity-bdd

我尝试使用kotlin为我的测试与宁静床框架,但是这不起作用例如 public class EndUserSteps { var dictionaryPage: DictionaryPage = null!! @Step fun enters(keyword: String) { dictionaryPage.enter_keywords(keyword) } @Step fun starts_search() { dictionaryPage.lookup_terms() } @Step fun should_see_definition(definition: String) { assertThat(dictionaryPage.definitions, hasItem(containsString(definition))) } @Step fun is_the_home_page() { dictionaryPage.open() } @Step fun looks_for(term: String) { enters(term) starts_search() } } 其他代码已经用Java编写了! 输出:(net.serenitybdd.core.exceptions.StepInitialisationException:无法为EndUserSteps创建步骤库:无法继承最终的类类ru.tinkoff.atesting.steps.serenity.EndUserSteps) 你可以帮我吗? 有什么想法?