groovy-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Wagenleitner <>
Subject Re: "continue" does not continue the while loop after an assertion fails
Date Tue, 12 Jan 2016 02:03:58 GMT
Could also put the text you were using in the asserts into a List instead
and after the while loop assert list isEmpty().
On Jan 11, 2016 5:28 PM, "Edinson E. Padrón Urdaneta" <> wrote:

> ​​
> ​​
> I don't really know what are your intentions, so I gonna try to guess and
> help you if I can:
> If you are trying to test every element in `exlusionList`, you don't want
> to stop the execution until the last one has been tested, and you want the
> test to fail if at least one element failed, you can use a flag to help you
> with that. Set the flag if the assertion failed at least once, and if the
> flag was set (it's true, for example) you can throw an exception to make
> the test fail as a whole.

View raw message