Agile

Handling Dynamically Changing Elements

Google+ Pinterest LinkedIn Tumblr

Quite often there are some elements and attributes that change dynamically on a page. For example – Say you have a currency conversion application. Today, 1 US Dollar would be equal to 0.89 Euros. The same dollar could be 0.90 Euros the very next day; as they change dynamically on a daily basis. In Testim, you have the following ways to handle dynamically changing elements-

Tip 1: Validating Dynamically Changing Elements

Whenever you want to validate dynamically changing elements, Testim has export parameters to handle this situation. 

For example – Say you want to validate the price of your flight trip. The price changes dynamically on a daily basis based on multiple factors. In this case, you can use export parameters; where in, you can store the element in an export variable and use the variable in different steps as parameters and also use it to do different validations in a page.

Tip 2: Generating random values during run time

Quite often there is a need to generate random values containing text, numbers and certain prefixes during run time. This is possible using the generate random value step in Testim. The value gets stored in a variable name which can be used in other steps as well. By default the variable name is randomValue.

Raj Subramanian a former developer, moved to testing to focus on his passion. Raj currently works as a Developer Evangelist for Testim.io, that provides AI based software testing solutions for clients. He actively contributes to the testing community by speaking at conferences, writing articles, blogging, making videos on his youtube channel and being directly involved in various testing-related activities. He currently resides in Chicago and can be reached at raj@testim.io. His website is www.rajsubra.com and twitter handle – @epsilon11. His videos on testing, leadership and productivity can be found here – http://www.rajsubra.com/my-youtube-channel/

Be smart & save time...
Simply automate.

Get Started Free