Skip to content

Commit 88cc365

Browse files
committed
add test suite to make order
1 parent 99d3d60 commit 88cc365

File tree

3 files changed

+56
-3
lines changed

3 files changed

+56
-3
lines changed
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
/*
2+
* Licensed to the Apache Software Foundation (ASF) under one or more
3+
* contributor license agreements. See the NOTICE file distributed with
4+
* this work for additional information regarding copyright ownership.
5+
* The ASF licenses this file to You under the Apache License, Version 2.0
6+
* (the "License"); you may not use this file except in compliance with
7+
* the License. You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS,
13+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
* See the License for the specific language governing permissions and
15+
* limitations under the License.
16+
*/
17+
package org.apache.dubbo.spring.boot;
18+
19+
import org.apache.dubbo.spring.boot.autoconfigure.CompatibleDubboAutoConfigurationTest;
20+
import org.apache.dubbo.spring.boot.autoconfigure.CompatibleDubboAutoConfigurationTestWithoutProperties;
21+
import org.apache.dubbo.spring.boot.autoconfigure.DubboAutoConfigurationOnMultipleConfigTest;
22+
import org.apache.dubbo.spring.boot.autoconfigure.DubboAutoConfigurationOnSingleConfigTest;
23+
import org.apache.dubbo.spring.boot.autoconfigure.RelaxedDubboConfigBinderTest;
24+
import org.apache.dubbo.spring.boot.context.event.AwaitingNonWebApplicationListenerTest;
25+
import org.apache.dubbo.spring.boot.context.event.DubboConfigBeanDefinitionConflictApplicationListenerTest;
26+
import org.apache.dubbo.spring.boot.context.event.OverrideDubboConfigApplicationListenerDisableTest;
27+
import org.apache.dubbo.spring.boot.context.event.OverrideDubboConfigApplicationListenerTest;
28+
import org.apache.dubbo.spring.boot.context.event.WelcomeLogoApplicationListenerTest;
29+
import org.apache.dubbo.spring.boot.env.DubboDefaultPropertiesEnvironmentPostProcessorTest;
30+
import org.apache.dubbo.spring.boot.util.DubboUtilsTest;
31+
import org.apache.dubbo.spring.boot.util.EnvironmentUtilsTest;
32+
33+
import org.junit.runner.RunWith;
34+
import org.junit.runners.Suite;
35+
36+
@RunWith(Suite.class)
37+
@Suite.SuiteClasses({
38+
CompatibleDubboAutoConfigurationTest.class,
39+
CompatibleDubboAutoConfigurationTestWithoutProperties.class,
40+
DubboAutoConfigurationOnMultipleConfigTest.class,
41+
DubboAutoConfigurationOnSingleConfigTest.class,
42+
RelaxedDubboConfigBinderTest.class,
43+
AwaitingNonWebApplicationListenerTest.class,
44+
DubboConfigBeanDefinitionConflictApplicationListenerTest.class,
45+
OverrideDubboConfigApplicationListenerDisableTest.class,
46+
OverrideDubboConfigApplicationListenerTest.class,
47+
WelcomeLogoApplicationListenerTest.class,
48+
DubboDefaultPropertiesEnvironmentPostProcessorTest.class,
49+
DubboUtilsTest.class,
50+
EnvironmentUtilsTest.class
51+
})
52+
public class TestSuite {
53+
}

dubbo-spring-boot-compatible/autoconfigure/src/test/java/org/apache/dubbo/spring/boot/CompatibleDubboAutoConfigurationTest.java renamed to dubbo-spring-boot-compatible/autoconfigure/src/test/java/org/apache/dubbo/spring/boot/autoconfigure/CompatibleDubboAutoConfigurationTest.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,10 @@
1414
* See the License for the specific language governing permissions and
1515
* limitations under the License.
1616
*/
17-
package org.apache.dubbo.spring.boot;
17+
package org.apache.dubbo.spring.boot.autoconfigure;
1818

1919
import org.apache.dubbo.config.spring.beans.factory.annotation.ReferenceAnnotationBeanPostProcessor;
2020
import org.apache.dubbo.config.spring.beans.factory.annotation.ServiceClassPostProcessor;
21-
import org.apache.dubbo.spring.boot.autoconfigure.DubboAutoConfiguration;
2221

2322
import org.junit.Assert;
2423
import org.junit.Test;

dubbo-spring-boot-compatible/autoconfigure/src/test/java/org/apache/dubbo/spring/boot/context/event/OverrideDubboConfigApplicationListenerTest.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
import org.junit.Test;
2626
import org.junit.runner.RunWith;
2727
import org.springframework.boot.test.context.SpringBootTest;
28+
import org.springframework.test.annotation.DirtiesContext;
2829
import org.springframework.test.context.TestPropertySource;
2930
import org.springframework.test.context.junit4.SpringRunner;
3031

@@ -47,6 +48,7 @@
4748
@SpringBootTest(
4849
classes = {OverrideDubboConfigApplicationListener.class}
4950
)
51+
@DirtiesContext(classMode = DirtiesContext.ClassMode.BEFORE_EACH_TEST_METHOD)
5052
public class OverrideDubboConfigApplicationListenerTest {
5153

5254
@BeforeClass
@@ -62,7 +64,6 @@ public static void destroy() {
6264

6365
@Test
6466
public void testOnApplicationEvent() {
65-
6667
Properties properties = ConfigUtils.getProperties();
6768

6869
Assert.assertEquals("dubbo-demo-application", properties.get("dubbo.application.name"));

0 commit comments

Comments
 (0)