tests: improved testable dialogs with better/colored logs and asserts (part of #13643, #13638);

This commit is contained in:
Oleg Agafonov 2025-06-14 21:10:32 +04:00
parent d43e96eaf2
commit a98f72649a
17 changed files with 123 additions and 83 deletions

View file

@ -74,14 +74,14 @@ class ChooseTargetTestableDialog extends BaseTestableDialog {
Targets.printDebugTargets(getGroup() + " - " + this.getName() + " - " + "FALSE", new Targets(choosingTarget), source, game, res);
}
((TargetTestableResult) this.getResult()).save(chooseRes, res, choosingTarget);
((TargetTestableResult) this.getResult()).onFinish(chooseRes, res, choosingTarget);
}
private ChooseTargetTestableDialog aiMustChoose(boolean status, int count) {
private ChooseTargetTestableDialog aiMustChoose(boolean resStatus, int targetsCount) {
TargetTestableResult res = ((TargetTestableResult) this.getResult());
res.aiAssert = true;
res.aiMustChooseStatus = status;
res.aiMustChooseTargetsCount = count;
res.aiAssertEnabled = true;
res.aiAssertResStatus = resStatus;
res.aiAssertTargetsCount = targetsCount;
return this;
}