[Python] Is this folder structure possible in Behave Selenium?

Discussão em 'Python' iniciado por Stack, Maio 13, 2025.

  1. Stack

    Stack Membro Participativo

    I'm currently refactoring our code and our organization wants to combine different repositories into 1 and now I'm arranging the folder structure.

    DIRECTORY STRUCTURE:
    +-- main_repository/
    +-- other_dev_folders/
    +-- testing/
    +-- another_folder_layer/
    +-- features/
    +-- platform1/
    | +-- platform1feature1.feature
    | +-- platform1feature2.feature
    +-- platform2/
    | +-- platform2feature1.feature
    | +-- platform2feature2.feature
    +-- steps/
    +-- common/
    | +-- common_steps.py
    +-- platform1/
    | +-- platform1feature1.py
    | +-- platform1feature2.py
    +-- platform2/
    | +-- platform2feature1.py
    | +-- platform2feature2.py
    +-- environment.py
    +-- web_pages_initializer.py
    +-- behave.ini


    I put the behave.ini with the following but still seems not working since it loads the steps in testing/steps instead of testing/another_folder_layer/steps

    [behave]
    paths = testing/another_folder_layer/features
    steps_dir = testing/another_folder_layer/steps
    format = plain
    color = true
    stdout_capture = false
    stderr_capture = false


    Not sure if this is possible in behave but can you give tips as to how to organize this? I tried running normally using behave testing/another_folder_layer/features/platform1/platform1feature1.feature but the steps are not recognized.

    Continue reading...

Compartilhe esta Página