mirror of
https://github.com/magefree/mage.git
synced 2025-12-20 02:30:08 -08:00
AI, tests: added stability tests to make sure AI simulations can process errors and freezes (part of #13638, #13766);
This commit is contained in:
parent
85c04bca59
commit
c3a0c731d6
12 changed files with 298 additions and 20 deletions
|
|
@ -196,7 +196,7 @@ public class ComputerPlayerMCTS extends ComputerPlayer {
|
|||
} catch (ExecutionException e) {
|
||||
// real games: must catch and log
|
||||
// unit tests: must raise again for fast fail
|
||||
if (this.isTestsMode()) {
|
||||
if (this.isTestMode() && this.isFastFailInTestMode()) {
|
||||
throw new IllegalStateException("One of the simulated games raise the error: " + e, e);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue