Skip to content

Commit 90183cc

Browse files
committed
Remove channelMessages collection before tests
The `MongoDbAvailableTests.cleanupCollections()` remove some collections before tests, but not `channelMessages` * Fix the `ConfigurableMongoDbMessageGroupStoreTests` to remove `channelMessages` collection, too
1 parent b2d7867 commit 90183cc

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

spring-integration-mongodb/src/test/java/org/springframework/integration/mongodb/store/ConfigurableMongoDbMessageGroupStoreTests.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2019 the original author or authors.
2+
* Copyright 2002-2020 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -117,7 +117,7 @@ private void performLazyLoadEagerTest(StopWatch watch, int sequenceSize, boolean
117117
@Test
118118
@MongoDbAvailable
119119
public void testWithCustomConverter() throws Exception {
120-
this.cleanupCollections(new SimpleMongoDbFactory(new MongoClient(), "test"));
120+
this.cleanupCollections(new SimpleMongoDbFactory(new MongoClient(), "test"), "channelMessages");
121121
ClassPathXmlApplicationContext context =
122122
new ClassPathXmlApplicationContext("ConfigurableMongoDbMessageStore-CustomConverter.xml", this.getClass());
123123
context.refresh();
@@ -131,7 +131,7 @@ public void testWithCustomConverter() throws Exception {
131131
@Test
132132
@MongoDbAvailable
133133
public void testPriorityChannel() throws Exception {
134-
this.cleanupCollections(new SimpleMongoDbFactory(new MongoClient(), "test"));
134+
this.cleanupCollections(new SimpleMongoDbFactory(new MongoClient(), "test"), "channelMessages");
135135
ClassPathXmlApplicationContext context =
136136
new ClassPathXmlApplicationContext("ConfigurableMongoDbMessageStore-CustomConverter.xml", this.getClass());
137137
context.refresh();

0 commit comments

Comments
 (0)