
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to create a Feature file for Cucumber in Java?
We can create a Feature file for Cucumber. This can be done using the below stepsβ
Step1β Click on the File menu in Eclipse. Then select the option New. Next click on Other
Step2β Click on Maven Project from the Maven folder. Then click on Next.
Step3β Proceed with the further steps.
Step4β Select maven-archetype-quickstart template. Then click on Next.
Step5β Add GroupId as Automation, Artifact Id as Cucumber, and proceed.
Step6β A project should get created with a Cucumber-type project structure. The Cucumber-related scripts should be written within the src/test/java folder.
Step6β Create a new package called features inside the src/test/java folder.
Step7β Create a feature file within the features package. Select the features package, then click on the File menu. Select option New->File.
Step8β Enter a file name, say Login with an extension as .feature. Then click on Finish.
Step10β A file called Login.feature should get created within the features package.