- Print
- DarkLight
Automating and Executing Tests
- Print
- DarkLight
Test Automation Tutorials
Test Modeller works with a wide-range of different frameworks, and with a variety of different automation scripting languages. It integrates natively with existing frameworks, automatically generating optimised tests and data to match their particular architecture and style.
Because of this flexibility, we provide a range of tutorials focusing on particular frameworks and languages. To automate test cases created in Test Modeller, please refer to these tutorials. We also provide a range of open source frameworks to help you get started. These are available within the tutorials.
Pre-Configured - Execution Commands
These are pre-configured commands to support the execution of automation scripts within Test Modeller.
When an automation framework is edited in Test Modeller, there is an 'execution' tab which contains the execution settings of a specific framework within your environment.
Java - Maven Project
Parameter | Value |
---|---|
Execution Command | C:\apache-maven-3.5.3\bin\mvn.cmd |
Execution Parameters | -Dtest=[filename] test |
Test Plans Explained
The Test Plan view in Test Modeller is a way to organize and execute Test Cases in plans that suit your team's needs.
Test Plans are comprised of Test Suites, which contain test cases from your Models. When a set of test cases are published into a Test Plan, it creates a new Test Suite.
Executing a Test Plan provides the ability to run a series of test cases whenever needed, with options to integrate them as part of your pipeline and share results with stakeholders.
Create a New Test Plan
There are two ways to create a new test plan: from the Test Plan Homepage and from a Model.
Create a Plan from the Test Plan Homepage
Inside the Modeller homepage, navigate to Tests → Test Plan. There is an option to Add a new Test Plan.
Create a Plan from a Model
You can also create a plan directly from a model by following the steps below under “Publish Test Cases”.
Publish Test Cases
Inside your Model, select the Test Cases you would like to include in your plan. Click Run → Automation Code → Settings Cog.
Under the Publish tab, you can upload these test cases into an existing Test Plan, or you can create a new one. Click Execute to upload.
You can publish test cases from various models under the same Test Plan.
The Test Plan Homepage
Inside the Modeller homepage, navigate to Tests → Test Plan. Here you can select which Test Plan to view, see the number of test suites it contains, whether it is on an automated execution schedule, and perform other actions.
The Run button will execute the Test Plan and run all of its Test Suites.
The Timer button will open a menu to schedule an automated execution of the plan. This is customizable by minutes, hours, daily, and weekly basis.
The Edit button allows you to change the test plan name.
The Delete button will delete the test suite.
View a Test Plan
After selecting a Test Plan to view, you can view the Test Suites it contains and perform various actions. The main header summarizes the number of passed and failed tests for your Test Plan. It also contains the option to run your plan, run only the failed tests, and to embed the plan into a pipeline.
For each Test Suite, the following information is provided:
- Number of individual tests it contains
- Framework it uses
- A link back to the model
- Run results
- The date it was created
- Whether it is currently enabled
- The option to manually execute the suite
Test Plan Settings
By clicking the Settings Cog in the header, you will have the option to change the following settings:
- Select a Test Data Allocation Server. By default, this is disabled.
- Select the Execution Type. By default, this will be the same execution chosen at the project level. For more information on setting up executions for different environments, please refer to this page: Multiple Automation Execution Types Explained
- Enable Email Summaries. This allows you to choose a user group to send a summary of the run results to. You can choose between sending all activity or only failed test results. For more information on creating user groups, please refer to this page: Test Modeller Best Practice
View Test Run Results
By expanding on the Test Suite, you can view the generated code for the test cases, as well as the individual test case results.
Enable and Disable Test Suites
By toggling the Enabled switch, you can temporarily remove Test Suites from your plan. This can be helpful when you want to execute only specific Test Suites. There is an option to hide disabled tests in the right hand corner.
Embed Test Plan into a Pipeline
Please refer to this video for instructions on implementing a test plan execution via an API request: Trigger Test Plan Execution through an API
How to Publish Tests
Publishing tests allows users to create comprehensive test plans from a variety of models within a project.
Inside your model, select the test cases you would like to include in your plan. Click Run → Automation Code → Settings Cog.
Under the Publish tab, you can upload these test cases into an existing Test Plan, or you can create a new one. Click Execute to upload.
You can publish test cases from various models under the same Test Plan.