Eclipse 如何删除JVM中不再存在于功能文件中的过时步骤函数?
我不熟悉使用EclipseIDE的JVM。通常,在使用Gherkin编写功能文件后,我使用Junit Runner运行功能文件,如下所示:Eclipse 如何删除JVM中不再存在于功能文件中的过时步骤函数?,eclipse,cucumber,cucumber-jvm,cucumber-java,Eclipse,Cucumber,Cucumber Jvm,Cucumber Java,我不熟悉使用EclipseIDE的JVM。通常,在使用Gherkin编写功能文件后,我使用Junit Runner运行功能文件,如下所示: @RunWith(Cucumber.class) @CucumberOptions( features = "Feature" ,glue={"stepDefinition"} ) public class CucumberTest { } 然后,Eclipse会提示我“您可以使用下面的代码段实现缺少的步骤”,并且会自动生成缺少的
@RunWith(Cucumber.class)
@CucumberOptions(
features = "Feature"
,glue={"stepDefinition"}
)
public class CucumberTest {
}
然后,Eclipse会提示我“您可以使用下面的代码段实现缺少的步骤”,并且会自动生成缺少的步骤函数定义:
@Given(xxxxx)
public void yyyy(String arg1, String arg2) throws Throwable {
// Write code here that turns the phrase above into concrete actions
throw new PendingException();
}
我只是复制并粘贴到我的步骤定义文件中,然后实现它。多方便啊
然而,有时我需要经常更改功能文件,这样Eclipse只会要求我添加新的或修改过的步骤定义,但它不会自动清除功能文件不再需要的旧步骤函数
那么,有没有办法通过不手动更改步骤定义来使其与要素文件保持一致
谢谢,可能的副本