Skip to content

Commit af45fec

Browse files
committed
enable timeout for tests
1 parent 4a39cc7 commit af45fec

5 files changed

Lines changed: 9 additions & 11 deletions

File tree

core/sail/api/src/test/java/org/eclipse/rdf4j/common/concurrent/locks/ExclusiveLockManagerTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ void cleanupUnreleasedLocksWithTracking() throws InterruptedException {
8686
}
8787

8888
@Test
89-
// @Timeout(2)
89+
@Timeout(2)
9090
void deadlockTest() throws InterruptedException {
9191

9292
Thread thread = null;
@@ -130,7 +130,7 @@ void deadlockTest() throws InterruptedException {
130130
}
131131

132132
@Test
133-
// @Timeout(2)
133+
@Timeout(2)
134134
void stalledTest() throws InterruptedException {
135135

136136
Lock exclusiveLock1 = lockManagerTracking.getExclusiveLock();

core/sail/api/src/test/java/org/eclipse/rdf4j/common/concurrent/locks/ExclusiveReentrantLockManagerTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ void cleanupUnreleasedLocksWithTracking() throws InterruptedException {
8888
}
8989

9090
@Test
91-
// @Timeout(2)
91+
@Timeout(2)
9292
void stalledTest() throws InterruptedException {
9393

9494
AtomicReference<Lock> exclusiveLock1 = new AtomicReference<>();

core/sail/api/src/test/java/org/eclipse/rdf4j/common/concurrent/locks/LockManagerTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ void cleanupUnreleasedLocks() throws InterruptedException {
6767
}
6868

6969
@Test
70-
// @Timeout(2)
70+
@Timeout(2)
7171
void cleanupUnreleasedLocksWithTracking() throws InterruptedException {
7272

7373
lock(lockManagerTracking);

core/sail/nativerdf/src/test/java/org/eclipse/rdf4j/sail/nativerdf/MemoryOverflowToDiskTest.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,12 @@
2222
import org.eclipse.rdf4j.model.Model;
2323
import org.eclipse.rdf4j.sail.base.SailStore;
2424
import org.junit.jupiter.api.Test;
25+
import org.junit.jupiter.api.Timeout;
2526

2627
public class MemoryOverflowToDiskTest {
2728

2829
@Test
29-
// @Timeout(5)
30+
@Timeout(5)
3031
public void testCleanerRemovesTempDirWhenMemoryOverflowModelGetsGCed() throws IOException, InterruptedException {
3132
File file = Files.createTempDirectory("model").toFile();
3233

testsuites/repository/src/main/java/org/eclipse/rdf4j/testsuite/repository/RepositoryTest.java

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515

1616
import java.util.List;
1717
import java.util.Objects;
18+
import java.util.concurrent.TimeUnit;
1819
import java.util.stream.Collectors;
1920

2021
import org.eclipse.rdf4j.model.IRI;
@@ -28,18 +29,14 @@
2829
import org.eclipse.rdf4j.repository.Repository;
2930
import org.eclipse.rdf4j.repository.RepositoryConnection;
3031
import org.eclipse.rdf4j.repository.RepositoryResult;
31-
import org.junit.jupiter.api.AfterAll;
32-
import org.junit.jupiter.api.AfterEach;
33-
import org.junit.jupiter.api.BeforeAll;
34-
import org.junit.jupiter.api.BeforeEach;
35-
import org.junit.jupiter.api.Test;
32+
import org.junit.jupiter.api.*;
3633

3734
/**
3835
* Integration test suite for implementations of Repository.
3936
*
4037
* @author Jeen Broekstra
4138
*/
42-
//@Timeout(value = 1, unit = TimeUnit.MINUTES)
39+
@Timeout(value = 1, unit = TimeUnit.MINUTES)
4340
public abstract class RepositoryTest {
4441

4542
@BeforeAll

0 commit comments

Comments
 (0)