03-04-2019 06:32 AM
Hi
I have to validate a string result in teststand.
The result is a String like this 00:02:15:1x:yz:qp, where x can be in the range 0-9 or a-f or A-F. The same for y, z, q and p.
How do I test for that?
For 00:02:15:1 i can just type "00:02:15:1" in Expected String Value:
But how do I test for the rest?
I know that I can use regular expressions like [0-9a-fA-F], but I can't write that into Expected String Value: directly.
Thanks in advance.
Bjarne
Solved! Go to Solution.
03-04-2019 03:14 PM
That isn't possible using the standard String Value Test. Any kind of advanced string comparison should be done in a code module. You could ake the test a Pass/Fail test and your code module use regular expressions to determine pass/fail. Alternatively, you could create a custom step where the code module is used as a post-step substep.