Featured Image

Parameterization in Testim | Boost Test Coverage Easily

Table of Contents

This Blog covers below major topics:

  • Random Value Generation
  • Parameterization
  • Insert Test Data From External File (Excel, Json etc)

Random Value Generation and Use that value in test

  • Click on Testim Predefined Steps → Click Actions → Click Generate Random Value.
  • Change its variable name, then use this variable in any action where you need the random value.

Parameterization

Parameterisation – Process of running the same test with different sets of data without modifying the test script

How To Achieve Parameterisation in Testim

  • Click on the first block named Setup (which contains the base URL).
  • Go to the Properties of this block.
  • Scroll down to Test Data and click on it.
  • Enter single or multiple test data in JSON format.

  • Now Call these variables (srnumber and prname) in your action block

  • When you run this test now, it will execute twice since we have two test datasets.
  • To verify this, go to Test Run from the left panel and click on the latest execution. You will see that the test was executed with two datasets.

Insert Test Data From External File (Excel, Json etc)

  • Click on the first block named Setup (which contains the base URL).
  • Go to the Properties of this block.
  • Scroll down to Test Data and click on it.
  • Click on Upload File and create a sample file as shown below.

  • Upload the sample file and run the tests. In my sample file, a single test will run three times with different datasets.

Good to Read:- Smart Locators & Self-Healing in Testim

Related Blogs