Skip to content

Commit

Permalink
HSEARCH-4157 Raise and uniform the timeout on JSR-351 tests
Browse files Browse the repository at this point in the history
  • Loading branch information
fax4ever authored and yrodiere committed Feb 18, 2021
1 parent 5977883 commit c53abc5
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 10 deletions.
Expand Up @@ -41,6 +41,8 @@ public abstract class AbstractBatchIndexingIT {
// We have three data templates per entity type (see setup)
protected static final int INSTANCE_PER_ENTITY_TYPE = INSTANCES_PER_DATA_TEMPLATE * 3;

static final int JOB_TIMEOUT_MS = 30_000;

protected JobOperator jobOperator;
protected EntityManagerFactory emf;

Expand Down
Expand Up @@ -45,8 +45,6 @@ public class BatchIndexingJobIT extends AbstractBatchIndexingIT {

private static final Log log = LoggerFactory.make( Log.class, MethodHandles.lookup() );

private static final int JOB_TIMEOUT_MS = 30_000;

/*
* Make sure to have more than one checkpoint,
* because we had errors related to that in the past.
Expand Down
Expand Up @@ -30,8 +30,6 @@ public class EntityManagerFactoryRetrievalIT extends AbstractBatchIndexingIT {

private static final String SESSION_FACTORY_NAME = "primary_session_factory";

private static final int JOB_TIMEOUT_MS = 10_000;

@Test
public void defaultNamespace() throws Exception {
List<Company> companies = JobTestUtil.findIndexedResults( emf, Company.class, "name", "Google" );
Expand Down
Expand Up @@ -7,6 +7,7 @@
package org.hibernate.search.integrationtest.batch.jsr352.massindexing;

import static org.assertj.core.api.Assertions.assertThat;
import static org.hibernate.search.integrationtest.batch.jsr352.massindexing.AbstractBatchIndexingIT.JOB_TIMEOUT_MS;

import java.time.LocalDate;
import java.time.temporal.ChronoUnit;
Expand Down Expand Up @@ -41,8 +42,6 @@ public class MassIndexingJobWithCompositeIdIT {

private static final String PERSISTENCE_UNIT_NAME = PersistenceUnitTestUtil.getPersistenceUnitName();

private static final int JOB_TIMEOUT_MS = 30_000;

private static final LocalDate START = LocalDate.of( 2017, 6, 1 );

private static final LocalDate END = LocalDate.of( 2017, 8, 1 );
Expand Down
Expand Up @@ -8,6 +8,7 @@

import static org.assertj.core.api.Assertions.assertThat;
import static org.hibernate.search.integrationtest.batch.jsr352.util.JobTestUtil.findIndexedResultsInTenant;
import static org.hibernate.search.integrationtest.batch.jsr352.massindexing.AbstractBatchIndexingIT.JOB_TIMEOUT_MS;

import java.io.IOException;
import java.util.Arrays;
Expand Down Expand Up @@ -45,8 +46,6 @@ public class MassIndexingJobWithMultiTenancyIT {

private static final String UNUSED_TENANT_ID = "unusedTenant";

private static final int JOB_TIMEOUT_MS = 10_000;

private SessionFactory sessionFactory;

private JobOperator jobOperator;
Expand Down
Expand Up @@ -7,6 +7,7 @@
package org.hibernate.search.integrationtest.batch.jsr352.massindexing;

import static org.junit.Assert.assertEquals;
import static org.hibernate.search.integrationtest.batch.jsr352.massindexing.AbstractBatchIndexingIT.JOB_TIMEOUT_MS;

import java.io.IOException;
import java.util.List;
Expand Down Expand Up @@ -41,8 +42,6 @@ public class RestartChunkIT {

private static final String PERSISTENCE_UNIT_NAME = PersistenceUnitTestUtil.getPersistenceUnitName();

private static final int JOB_TIMEOUT_MS = 10_000;

protected static final long DB_COMP_ROWS = 150;

private JobOperator jobOperator;
Expand Down

0 comments on commit c53abc5

Please sign in to comment.