This commit is contained in:
Alexey Kudravtsev
2016-02-10 10:37:20 +03:00
parent 94863a8df4
commit f1668d49c6
3 changed files with 7 additions and 5 deletions
@@ -37,6 +37,7 @@ import com.intellij.util.Alarm;
import com.intellij.util.PathUtil;
import com.intellij.util.ThrowableRunnable;
import org.jetbrains.annotations.NonNls;
import org.jetbrains.annotations.NotNull;
import java.io.File;
import java.util.Arrays;
@@ -179,7 +180,7 @@ public abstract class ExecutionTestCase extends IdeaTestCase {
return myModuleOutputDir.getAbsolutePath();
}
public void waitProcess(final ProcessHandler processHandler) {
public void waitProcess(@NotNull final ProcessHandler processHandler) {
Alarm alarm = new Alarm(Alarm.ThreadToUse.SHARED_THREAD, getTestRootDisposable());
final boolean[] isRunning = {true};
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2015 JetBrains s.r.o.
* Copyright 2000-2016 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -21,6 +21,7 @@ import com.intellij.openapi.util.Key;
import com.intellij.openapi.util.UserDataHolderBase;
import com.intellij.util.concurrency.Semaphore;
import com.intellij.util.containers.ContainerUtil;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;
import java.io.OutputStream;
@@ -242,7 +243,7 @@ public abstract class ProcessHandler extends UserDataHolderBase {
runPendingTasks();
}
public void execute(Runnable task) {
public void execute(@NotNull Runnable task) {
if (isStartNotified()) {
task.run();
}
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2015 JetBrains s.r.o.
* Copyright 2000-2016 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -76,7 +76,7 @@ public class ProcessWaitFor {
myWaitForThreadFuture.cancel(true);
}
public void setTerminationCallback(Consumer<Integer> r) {
public void setTerminationCallback(@NotNull Consumer<Integer> r) {
myTerminationCallback.offer(r);
}
}