mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-18 09:34:34 +07:00
- Artifact roots are not marked as "generated sources".
- To properly mark artifact sources as up-to-date, compilation-start timestamp is advanced for every chunk/group of chunks before starting compilation
This commit is contained in:
@@ -35,6 +35,7 @@ import junit.framework.Assert;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
import org.jetbrains.jps.util.JpsPathUtil;
|
||||
|
||||
import javax.swing.*;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.util.Arrays;
|
||||
@@ -209,10 +210,10 @@ public abstract class BaseCompilerTestCase extends ModuleTestCase {
|
||||
private CompilationLog compile(final ParameterizedRunnable<CompileStatusNotification> action) {
|
||||
final Ref<CompilationLog> result = Ref.create(null);
|
||||
final Semaphore semaphore = new Semaphore();
|
||||
semaphore.down();
|
||||
UIUtil.invokeAndWaitIfNeeded(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
semaphore.down();
|
||||
|
||||
CompilerManagerImpl.testSetup();
|
||||
final CompileStatusNotification callback = new CompileStatusNotification() {
|
||||
@@ -240,14 +241,18 @@ public abstract class BaseCompilerTestCase extends ModuleTestCase {
|
||||
}
|
||||
});
|
||||
|
||||
long start = System.currentTimeMillis();
|
||||
final long start = System.currentTimeMillis();
|
||||
while (!semaphore.waitFor(10)) {
|
||||
if (System.currentTimeMillis() - start > 60 * 1000) {
|
||||
throw new RuntimeException("timeout");
|
||||
}
|
||||
if (SwingUtilities.isEventDispatchThread()) {
|
||||
UIUtil.dispatchAllInvocationEvents();
|
||||
}
|
||||
}
|
||||
if (SwingUtilities.isEventDispatchThread()) {
|
||||
UIUtil.dispatchAllInvocationEvents();
|
||||
}
|
||||
UIUtil.dispatchAllInvocationEvents();
|
||||
|
||||
return result.get();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user