使用黄瓜框架运行groovy步骤定义

时间:2017-01-06 19:27:59

标签: android-studio groovy cucumber

我正在尝试使用常规步骤定义在android studio中运行Cucumber测试。为什么我在运行日志中收到以下错误消息?

org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
C:\Users\BSI-Laptop-2\AndroidStudioProjects\AnotherNewProject\app\src\test\groovy\StepDefinitions.groovy: 6: unable to resolve class cucumber.api.java.en.When
 @ line 6, column 1.
   import cucumber.api.java.en.When
   ^

C:\Users\BSI-Laptop-2\AndroidStudioProjects\AnotherNewProject\app\src\test\groovy\StepDefinitions.groovy: 3: unable to resolve class cucumber.api.java.en.And
 @ line 3, column 1.
   import cucumber.api.java.en.And
   ^

C:\Users\BSI-Laptop-2\AndroidStudioProjects\AnotherNewProject\app\src\test\groovy\StepDefinitions.groovy: 4: unable to resolve class cucumber.api.java.en.Given
 @ line 4, column 1.
   import cucumber.api.java.en.Given
   ^

C:\Users\BSI-Laptop-2\AndroidStudioProjects\AnotherNewProject\app\src\test\groovy\StepDefinitions.groovy: 5: unable to resolve class cucumber.api.java.en.Then
 @ line 5, column 1.
   import cucumber.api.java.en.Then
   ^

4 errors


Process finished with exit code 1

0 个答案:

没有答案