Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

multiple-steps-directories-under-steps #1151

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

dron4ik86
Copy link

Updated load_step_definitions method to recursively search and load step definition files from nested directories within features/steps. This ensures all step files, even those deeply nested, are correctly recognized and loaded by Behave.
Previously, Behave was skipping feature files in nested structures like this:

features/
    ├── some_feature.feature
    └── steps/
        └── sub_folder_1/
            └── subfolder/
                └── nested_steps.py (Not executed properly)

Enhanced step discovery now encompasses all nested directories, ensuring availability of step definitions at any nesting level for feature tests. Corresponding tests have been added to validate this enhancement.

… .py files within the steps/ directory and its subdirectories, enabling the loading of step files from nested folders.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant