[Demonstration 1]

[Buggy Method]
@Override
public boolean perform(AbstractBuild<?, ?> build, Launcher launcher, BuildListener listener) throws InterruptedException, IOException {
    final PrintStream logger = listener.getLogger();
    // Gather list of platforms specified by Android project files in the workspace
    log(logger, Messages.FINDING_PROJECTS());
    Collection<String> platforms = build.getWorkspace().act(new ProjectPlatformFinder(listener));
    if (platforms == null || platforms.isEmpty()) {
        // Nothing to install, but that's ok
        log(logger, Messages.NO_PROJECTS_FOUND_FOR_PREREQUISITES());
        return true;
    }
    // Ensure we have an SDK
    AndroidSdk androidSdk = getAndroidSdk(build, launcher, listener);
    if (androidSdk == null) {
        return false;
    }
    // Install platform(s)
    log(logger, Messages.ENSURING_PLATFORMS_INSTALLED(platforms));
    for (String platform : platforms) {
        SdkInstaller.installPlatform(logger, launcher, androidSdk, platform, false);
    }
    // Done!
    return true;
}

[Buggy Hunk]
SdkInstaller.installPlatform(logger, launcher, androidSdk, platform, false);

[Patch]
SdkInstaller.installPlatform(logger, launcher, androidSdk, platform, null);

[Demonstration 2]

[Buggy Method]
@Test
public void testUpdatePositionsAfterBetaReduction() {
    app.setfamily(new Application());
    app.updatePositionsAfterBetaReduction();
}

[Buggy Hunk]
app.setfamily(new Application());

[Patch]
app.setFamily(new Application());

[Demonstration 3]

[Buggy Method]
@Override
public void start() {
    isRunning = true;
    if (isTriggered) {
        isTriggered = false;
        isFinished = false;
        roundView.setText(String.format("%d/%d", roundNumber + 1, maxRoundNumber));
        currentTimer.start();
        Runnable brunnable = new Runnable() {

            @Override
            public void run() {
                while (isRunning && !isFinished) {
                    try {
                        Thread.sleep(500);
                    } catch (InterruptedException e) {
                        e.printStackTrace();
                    }
                    handler.post(new Runnable() {

                        @Override
                        public void run() {
                            decideStrategy();
                        }
                    });
                }
            }
        };
        thread = new Thread(brunnable);
        thread.start();
    }
}

[Buggy Hunk]
roundView.setText(String.format("%d/%d", roundNumber + 1, maxRoundNumber));

[Patch]
roundView.setText(String.format("%d/%d", roundNumber, maxRoundNumber));