首页 > 其他分享 >Is it correct that a .feature file always maps to a step file?

Is it correct that a .feature file always maps to a step file?

时间:2023-02-09 17:55:50浏览次数:38  
标签:files definition always feature maps step file

Is it correct that a .feature file always maps to a step file?

Not necessarily. A .feature file in Cucumber or SpecFlow describes a feature or user story in the application under test. The steps in the .feature file are implemented in step definition files, which contain the code that will be executed for each step in the scenario.

So, in general, a .feature file maps to one or more step definition files. However, you can also have multiple .feature files that map to the same step definition file, especially when the steps are reused across multiple scenarios.

In summary, there is a one-to-many relationship between .feature files and step definition files, with each .feature file potentially mapping to multiple step definition files.

 

 

标签:files,definition,always,feature,maps,step,file
From: https://www.cnblogs.com/chucklu/p/17106527.html

相关文章