iqa-automation-framework
Evaluted from cucumber-selenium-framework
Selenium WebDriver and Appium based Web, Mobile (Android, iOS) and Windows desktop Automation Framework with BDD implementation support
Features
- With few Configurations and adding dependencies, you are ready to use this framework
- Framework supports to test web application, Mobile application (Native, Web, Hybrid), Windows Native applications
- BDD based Framework:
- Tag based scenarios
- Tag based execution
- Parallel and Sequential execution support
- Selenium Grid Support: It helps in running multiple tests across different browsers, operating systems, and machines in parallel
- Database support- Do database Configuration and use it (MySQL, Oracle, etc.)
- Test Data management facility at run time, global, static, Test script level
- Logger and Reports Facility:
- Test method level - Using Extent Report
- Framework level - Using Log4j
How To Start/Use
- Create simple maven project in Eclipse
- Get framework project from git and add following dependency and sure-fire plug in information in POM file Dependency:
<dependencies>
<dependency>
<groupId>io.github.innovativeqalabgroupId>
<artifactId>test-automation-frameworkartifactId>
<version>0.0.2version>
dependency>
dependencies>
- Create page object classes src/test/java folder
- Create feature file/s in src/test/resources/feature folder and corresponding step definitions in src/test/java folder
- Create testNG.xml file in src/test/resources folder
- Create required configuration files in src/test/resources folder
- WebDriverConfig.properties
- Environment.properties
Please refer sample project "orange-hrm" for more details
Properties file configurations
-
WebDriverConfig.properties is the important file which decides whether to run the tests locally or on remote machines. It contains following important items
- Driver mode : Remote or Local. Specify DRIVER=REMOTE for facilitating remote execution using remote driver. RemoteWebDriver capabilities must set in respective property files in src/test/resources/capabilities folder. DRIVER=BROWSER for execution on local machine.
- Platform : WINDOWS or LINUX or IOS or ANDROID ...
- Browser Name : Specify the browser you want to use
- Browser Version : Specify the browser version. If not specified, it will consider the default one.
- Driver Executables : Specify the complete path to driver exe. If Driver Mode is 'Remote', this property is not required.
- Driver Property Name : Specify property name of the driver e.g for chrome driver, 'web driver.chrome.driver'. If Driver Mode is 'Remote', this property is not required.
- Hub Url : This is required if the Driver Mode is Remote. Specify the selenium grid hub url or appium url as applicable
-
Environment.properties file will have name of the environment. Corresponding to each environment e.g QA, there needs be properties file in the user-defined folder like 'QAEnvironmentConfig.properties'. This file will have environment URL and other environment specific properties.
-
Capabilities : This folder will contain Browser, iOS, Android etc specific properties in the separate files as per our need. Please refer to sample project 'orange-hrm' for more details.
XML file configurations
TestNG xml file gives facility to execute test scripts as per our requirement. We need to provide the parameters which is mandatory for the execution of scripts and also as per our need
- Parallel execution threads control:
<suite name="Selenium-Cucumber-Test" parallel="methods" data-provider-thread-count="10" >
- Provide Feature File/Folder Path:
<parameter name="featureFilePath" value="src/test/resources/feature/"/>