Forum Discussion
PaulDonny
12 years agoRegular Contributor
Glad you figured it out. Personally, I would remove the assertion there and give that responsibility to your groovy script.
Also, the way it works, if you test case was to actually fail, how would you prevent it from being a simulated infinite loop? Do you have any sort of checks or balances to say after xx amount of time passes, we no longer care if the email is sent?
If you wanted to do that, store a property with the time that it started, check if the property exists (if not set it) and if more than the allotted time has passed (if so fail it all). When the script finds the email, have it remove the property.
Also, the way it works, if you test case was to actually fail, how would you prevent it from being a simulated infinite loop? Do you have any sort of checks or balances to say after xx amount of time passes, we no longer care if the email is sent?
If you wanted to do that, store a property with the time that it started, check if the property exists (if not set it) and if more than the allotted time has passed (if so fail it all). When the script finds the email, have it remove the property.