### Question:
AbstractExecutor implements Executor { @Override public void run(BuildExecutionContext context) { if (buildDialog.isBuilding()) { return; } validator.validate(context); buildDialog.startBuild(); start(context); } AbstractExecutor(Caller<BuildService> buildServiceCaller, Event<BuildResults> buildResultsEvent, Event<NotificationEvent> notificationEvent, BuildDialog buildDialog, ContextValidator validator); @Override void run(BuildExecutionContext context);  }### Answer:
@Test public void testValidation() { Assertions.assertThatThrownBy(() -> { if (context.getModule().getPom().getGav().isSnapshot()) { runner.run(getDefaultContext()); } else { runner.run(getSnapshotContext()); } }).isInstanceOf(IllegalArgumentException.class); }