Execute Tests (Java)
November 17, 2020
|By Roberta Catizone
Search Knowledge Base by Keyword
Created OnNovember 17, 2020
byRoberta Catizone
< Back
Execute Automated Tests
Take the automation scripts generated by TestModeller.io and integrate them into your automation framework for execution.
Integrate Automation Into Framework
- Open the Results.zip file previously downloaded.
- Navigate to code folder – here you will see the .java files that have been autogenerated by TestModeller.io.
- Copy the generated java file into the automation framework. Navigate to the framework\src\test\java\Tests folder and paste the file.
- It is useful to do a new compile to check all the code is valid and operational.
Note if you have pasted this into a different location within the framework you may need to adjust the import statements to reflect the new framework structure of the code.
Execute Tests
You can run the tests within the IntelliJ IDE by right clicking on the test case and selecting to run it. Here we will run the entire test suite through the command line.
- Navigate to the Java framework directory (this location should contain the pom.xml file in the root).
- Run mvn test. You should see your tests execute.
Tip
TestNG
The example automation framework uses TestNG as the test execution runner and results engine. You can tag tests, and also specify exactly which tests to run within TestNG either on your local machine or within your CI execution environment. We reccomend referring to the TestNG documentation here to learn more about configuring TestNG for your requirements.
-
-
-
- IEnumerable to Data Reader
- Data Table to List
- Nested String List to Data Table
- List to Data Table
- IEnumerable to List
- List to IEnumerable
- Remove from List
- Exists in List
- Value Exists in Dictionary
- Key Exists in Dictionary
- Remove from Dictionary
- Get from Dictionary
- Clear Dictionary
- Add to Dictionary
- Clear List
- Add to List
- Show all articles ( 1 ) Collapse Articles
-
-
-
-
- Explanation of Remaining Sheets in the Control Spreadsheet (for reference only)
- The ForeignKeys Sheet - Specifying which Foreign Keys to read from the Source Database
- The Tables Sheet: Defining Metadata that will be read from the Source Database
- The ProcessModel sheet – Toggling Subset Rules
- Refining the Control Spreadsheet
- Overview of the Advanced Control Spreadsheet
- Introduction
-
- Drop both Primary and Foreign Keys (The composite DROPKEYS Action)
- Validate Both Primary and Foreign Keys (The composite ValidateKeys Action)
- Add Both Primary and Foreign Keys (The Composite ADDKEYS action)
- Drop Tables
- Truncate Data
- Delete Orphans
- Drop Primary Keys
- Drop Foreign Keys
- Validate that Foreign Keys are Unique
- Validate that Primary Keys are Unique
- Add Foreign Keys
- Add Primary Keys
- Overview of Post-Subset Actions
-
-
- Use Event Hooks to call VIP Flows
- Different Methods for Connecting to Source Databases
- PreProcess Variables and Parameters
- Using SQL Functions to query Databases and Using the Queries in Data Generation Functions
- Summary of the Process to Configure the Test Data Configuration sheet
- How the PreProcessVariables Table is used in the Configuration sheet
- Sample Commerce Configuration Sheet Examples
- Adding Event Hooks in Configuration sheet for custom functionality
- How to Configure the Synthetic Test Data Configuration Control Sheet
-
-
-
-
-
- The UI Recorder
- Test Modeller – Maintenance
- Test Modeller Core (Linux) Optional – Postgres LDAP
- Test Modeller Core (Linux) Optional – SSL Certificate Installation
- Test Modeller Core (Linux) Optional – Active Directory
- Test Modeller Core (Linux) Installation
- Test Modeller: Software Pre-requisites
- Test Modeller : Installation components
- Test Modeller : System requirements (Windows, Linux)
-
-
-
-
-
-
- Common Problems
- Extend Test Modeller (Advanced)
- Edit Code Templates (Advanced)
- Import existing framework / custom page objects (Advanced)
- Execute Tests (Java)
- Generate Automation Code
- Build a Model (Java)
- Scan an Existing Web App
- Configuration (Java)
- Prerequisites (Selenium Java)
- Welcome Selenium (Java)
-
-
-
-
- Generate Optimised Test Cases and Data into Excel
- Implement Naming Conventions
- Page Object Generation
- Intelligent Page Objects
- Customising Page Objects
- Import Custom Code Snippets
- Rule-Based Test Generation
- Trigger Automation Execution from within Test Modeller
- Automation Configuration
- Test Data Automation for Gherkin Specifications
-
-