FrameWork Design Structure

Below is the framework structure which we normally follow in the TestAutomation framework.

There are totally 5 packages and 2 folders in the framework structure of TestAutomation.Let us discuss one by one now.

Framework Structure

Base Package:

In this package we need to create two classes.

  • Driver.py class
  • BasePage.py class


Driver.py class : In this class we will create a browser driver method.

BasePage.py class : In this class we will create all the customized methods which are required for automation like click , send_text , find_element() , find_elements() methods etc along with all the logs configuration as well.

Utilities Package:

In this package will create a class for log4j configuration and report methods etc.

Pages Package:

In this package we will create multiple classes based on screens or webpages.

Each .py class consists of WebElement locator values of each screen.In this way it's very easy to modify whenever they update or change the locatore value.

Configuration Package:

In this package we will create configuration files which have values that pass in Driver.py class etc.

Report Folder:

In this folder we will store all the report files after executing our scripts.

Screenshots Folder:

In this folder we will store all the screenshots for failed cases or any other screenshots which require verification.

Tests Packages:

In this package we will create all the test files according to test cases along with TestSuite.py file.


Framework Structure