@Test public void testStartBuildWithBuidAlreadyRunning() { checkStartBuild(); Assertions.assertThatThrownBy(() -> dialog.startBuild()) .isInstanceOf(IllegalStateException.class) .hasMessage("Build already running"); }
public void startBuild() { if (building) { throw new IllegalStateException("Build already running"); } building = true; }
BuildDialog { public void startBuild() { if (building) { throw new IllegalStateException("Build already running"); } building = true; } }
BuildDialog { public void startBuild() { if (building) { throw new IllegalStateException("Build already running"); } building = true; } @Inject  BuildDialog(BuildDialogView view); }
BuildDialog { public void startBuild() { if (building) { throw new IllegalStateException("Build already running"); } building = true; } @Inject  BuildDialog(BuildDialogView view); boolean isBuilding(); void startBuild(); void stopBuild(); void showBusyIndicator(String message); void hideBusyIndicator(); }
BuildDialog { public void startBuild() { if (building) { throw new IllegalStateException("Build already running"); } building = true; } @Inject  BuildDialog(BuildDialogView view); boolean isBuilding(); void startBuild(); void stopBuild(); void showBusyIndicator(String message); void hideBusyIndicator();  }