Test Studio’s IF Conditional steps are extraordinarily handy feature which enable you to handle branching in your tests based on specific conditions. There are a number of scenarios where this can ensure your tests are a bit more robust—logging in to your system if needed is one example. (Note: There are also many situations where I recommend against using conditionals. Don’t use them to conflate separate test cases. Keep your test cases simple, specific, and granular!)

Here’s a tip I just learned today: Editing an IF conditional’s verification. This is nice feature because it allows you to update your conditional without having to add in a completely different verification and replace the existing one.

Select the test step with the IF in it, then scroll down the properties window to the Verifications node. Expand that and you’ll have full access to all the context-specific properties of the verification that was embedded in to the IF. You can change comparison strings, types, etc., all from these fields!

image

About the author

Jim Holmes

Jim Holmes

has around 25 years IT experience. He is co-author of "Windows Developer Power Tools" and Chief Cat Herder of the CodeMash Conference. He's a blogger and evangelist for Telerik’s Test Studio, an awesome set of tools to help teams deliver better software. Find him as @aJimHolmes on Twitter.


Related Posts

Comments

Comments are disabled in preview mode.