mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-31 17:39:05 +00:00
ACS-5451: Toggle for direct Event sending (#2156)
* ACS-5451: Toggle for direct Event sending - fixing failing tests in enterprise-repo
This commit is contained in:
committed by
GitHub
parent
2f77cdd94f
commit
9207fde808
@@ -35,6 +35,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|||||||
import org.springframework.beans.factory.config.BeanPostProcessor;
|
import org.springframework.beans.factory.config.BeanPostProcessor;
|
||||||
import org.springframework.context.annotation.Bean;
|
import org.springframework.context.annotation.Bean;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
|
import org.springframework.test.annotation.DirtiesContext;
|
||||||
import org.springframework.test.context.ContextConfiguration;
|
import org.springframework.test.context.ContextConfiguration;
|
||||||
import org.springframework.test.context.ContextHierarchy;
|
import org.springframework.test.context.ContextHierarchy;
|
||||||
|
|
||||||
@@ -42,6 +43,7 @@ import org.springframework.test.context.ContextHierarchy;
|
|||||||
// Context hierarchy inherits context config from parent classes and extends it with TestConfig from this class
|
// Context hierarchy inherits context config from parent classes and extends it with TestConfig from this class
|
||||||
@ContextConfiguration(classes = DirectEventGeneratorTest.TestConfig.class)
|
@ContextConfiguration(classes = DirectEventGeneratorTest.TestConfig.class)
|
||||||
})
|
})
|
||||||
|
@DirtiesContext(classMode = DirtiesContext.ClassMode.BEFORE_CLASS)
|
||||||
public class DirectEventGeneratorTest extends EventGeneratorTest
|
public class DirectEventGeneratorTest extends EventGeneratorTest
|
||||||
{
|
{
|
||||||
@Autowired
|
@Autowired
|
||||||
|
@@ -27,7 +27,9 @@ package org.alfresco.repo.event2;
|
|||||||
|
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.test.annotation.DirtiesContext;
|
||||||
|
|
||||||
|
@DirtiesContext(classMode = DirtiesContext.ClassMode.BEFORE_CLASS)
|
||||||
public class EnqueuingEventGeneratorTest extends EventGeneratorTest
|
public class EnqueuingEventGeneratorTest extends EventGeneratorTest
|
||||||
{
|
{
|
||||||
@Autowired
|
@Autowired
|
||||||
|
@@ -37,7 +37,6 @@ import jakarta.jms.Message;
|
|||||||
import jakarta.jms.MessageConsumer;
|
import jakarta.jms.MessageConsumer;
|
||||||
import jakarta.jms.MessageListener;
|
import jakarta.jms.MessageListener;
|
||||||
import jakarta.jms.Session;
|
import jakarta.jms.Session;
|
||||||
|
|
||||||
import org.alfresco.model.ContentModel;
|
import org.alfresco.model.ContentModel;
|
||||||
import org.alfresco.repo.event.v1.model.RepoEvent;
|
import org.alfresco.repo.event.v1.model.RepoEvent;
|
||||||
import org.alfresco.service.cmr.repository.NodeRef;
|
import org.alfresco.service.cmr.repository.NodeRef;
|
||||||
@@ -52,9 +51,7 @@ import org.junit.After;
|
|||||||
import org.junit.Before;
|
import org.junit.Before;
|
||||||
import org.junit.BeforeClass;
|
import org.junit.BeforeClass;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
import org.springframework.test.annotation.DirtiesContext;
|
|
||||||
|
|
||||||
@DirtiesContext(classMode = DirtiesContext.ClassMode.BEFORE_CLASS)
|
|
||||||
public abstract class EventGeneratorTest extends AbstractContextAwareRepoEvent
|
public abstract class EventGeneratorTest extends AbstractContextAwareRepoEvent
|
||||||
{
|
{
|
||||||
private static final String EVENT2_TOPIC_NAME = "alfresco.repo.event2";
|
private static final String EVENT2_TOPIC_NAME = "alfresco.repo.event2";
|
||||||
|
@@ -35,8 +35,8 @@ import org.junit.runners.Suite.SuiteClasses;
|
|||||||
DeleteRepoEventIT.class,
|
DeleteRepoEventIT.class,
|
||||||
ChildAssociationRepoEventIT.class,
|
ChildAssociationRepoEventIT.class,
|
||||||
PeerAssociationRepoEventIT.class,
|
PeerAssociationRepoEventIT.class,
|
||||||
EnqueuingEventGeneratorTest.class,
|
|
||||||
DirectEventGeneratorTest.class,
|
DirectEventGeneratorTest.class,
|
||||||
|
EnqueuingEventGeneratorTest.class,
|
||||||
EventGeneratorDisabledTest.class
|
EventGeneratorDisabledTest.class
|
||||||
})
|
})
|
||||||
public class RepoEvent2ITSuite
|
public class RepoEvent2ITSuite
|
||||||
|
Reference in New Issue
Block a user