Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
dfc53aa
feat: optimize test
wardseptember Jan 16, 2026
3fbb6d0
feat: optimize test
wardseptember Jan 16, 2026
4a7f3ac
feat: optimize test
wardseptember Jan 16, 2026
ef5057d
feat: optimize trpc-container test
wardseptember Jan 16, 2026
c8f927e
Merge remote-tracking branch 'upstream/JDK17/Springboot3' into feat/o…
wardseptember Jan 19, 2026
8e6543c
feat: optimize trpc-core test
wardseptember Jan 19, 2026
146b627
feat: optimize trpc-core test
wardseptember Jan 19, 2026
cb67b58
feat: optimize trpc-core test
wardseptember Jan 20, 2026
0025a5b
feat: optimize ci and codecov
wardseptember Jan 20, 2026
135f762
feat: optimize trpc-transport test
wardseptember Jan 21, 2026
0ba0f08
Merge remote-tracking branch 'upstream/JDK17/Springboot3' into feat/o…
wardseptember Jan 27, 2026
67f3903
Merge remote-tracking branch 'upstream/JDK17/Springboot3' into feat/o…
wardseptember Feb 2, 2026
c989fc4
feat: optimize trpc-proto test
wardseptember Feb 2, 2026
7eb4de5
Merge remote-tracking branch 'upstream/JDK17/Springboot3' into feat/o…
wardseptember Feb 2, 2026
b0e9a55
feat: optimize trpc-spring-support test
wardseptember Feb 4, 2026
9a12cce
feat: optimize trpc-spring-support test
wardseptember Feb 4, 2026
d571975
feat: optimize trpc-spring-support test
wardseptember Feb 4, 2026
eaed7c3
Merge remote-tracking branch 'refs/remotes/upstream/JDK17/Springboot3…
wardseptember Feb 4, 2026
fccff83
feat: optimize trpc-spring-cloud-gateway test
wardseptember Feb 4, 2026
0a8c9e8
Merge remote-tracking branch 'upstream/JDK17/Springboot3' into feat/o…
wardseptember Feb 4, 2026
07af162
Merge remote-tracking branch 'upstream/JDK17/Springboot3' into feat/o…
wardseptember Feb 6, 2026
60fdccc
feat: optimize trpc-spring-boot-starter test
wardseptember Feb 9, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
import com.tencent.trpc.spring.boot.starters.test.GreeterService;
import com.tencent.trpc.spring.boot.starters.test.HelloRequestProtocol.HelloRequest;
import com.tencent.trpc.spring.boot.starters.test.HelloRequestProtocol.HelloResponse;
import javax.annotation.Resource;
import jakarta.annotation.Resource;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,16 @@
import com.tencent.trpc.spring.boot.starters.test.HelloRequestProtocol.HelloRequest;
import com.tencent.trpc.spring.boot.starters.test.HelloRequestProtocol.HelloResponse;
import com.tencent.trpc.spring.boot.starters.test.SpringBootTestApplication;
import javax.annotation.Resource;
import org.junit.Assert;
import org.junit.Test;
import org.junit.runner.RunWith;
import jakarta.annotation.Resource;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.context.SpringBootTest.WebEnvironment;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;

@RunWith(SpringJUnit4ClassRunner.class)
@SpringBootTest(classes = SpringBootTestApplication.class, webEnvironment = WebEnvironment.NONE)
@ContextConfiguration(classes = EnableAnnotationTestConfiguration.class)
public class EnableAnnotationTest {
Expand All @@ -45,25 +42,25 @@ public void contextLoad() {

HelloResponse hello = demoService.sayHello(HelloRequest.newBuilder().setMessage("hello").build());

Assert.assertEquals("hello", hello.getMessage());
Assert.assertNotNull(demoService.getGreeterService1Bean());
Assert.assertNotNull(demoService.getGreeterService2Bean());
Assert.assertNotNull(demoService.getMyTestServer());
Assert.assertSame(demoService.getGreeterService(), demoService.getGreeterService1Bean());
Assert.assertSame(demoService.getGreeterService2(), demoService.getGreeterService2Bean());
Assert.assertSame(demoService.getMyTestServerClient(), demoService.getMyTestServer());
Assertions.assertEquals("hello", hello.getMessage());
Assertions.assertNotNull(demoService.getGreeterService1Bean());
Assertions.assertNotNull(demoService.getGreeterService2Bean());
Assertions.assertNotNull(demoService.getMyTestServer());
Assertions.assertSame(demoService.getGreeterService(), demoService.getGreeterService1Bean());
Assertions.assertSame(demoService.getGreeterService2(), demoService.getGreeterService2Bean());
Assertions.assertSame(demoService.getMyTestServerClient(), demoService.getMyTestServer());
}

@Test
public void testFilterInject() {
AutoInjectTestFilter filter = (AutoInjectTestFilter) FilterManager.get("auto_inject_test_filter");
Assert.assertSame(filter, autoInjectTestFilter);
Assert.assertNotNull(filter.getGreeterService());
Assert.assertNotNull(filter.getGreeterService2());
Assert.assertNotNull(filter.getMyTestServer());
Assert.assertSame(filter.getGreeterService(), demoService.getGreeterService1Bean());
Assert.assertSame(filter.getGreeterService2(), demoService.getGreeterService2Bean());
Assert.assertSame(filter.getMyTestServer(), demoService.getMyTestServer());
Assertions.assertSame(filter, autoInjectTestFilter);
Assertions.assertNotNull(filter.getGreeterService());
Assertions.assertNotNull(filter.getGreeterService2());
Assertions.assertNotNull(filter.getMyTestServer());
Assertions.assertSame(filter.getGreeterService(), demoService.getGreeterService1Bean());
Assertions.assertSame(filter.getGreeterService2(), demoService.getGreeterService2Bean());
Assertions.assertSame(filter.getMyTestServer(), demoService.getMyTestServer());
}

@Configuration
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,13 @@
import com.tencent.trpc.spring.boot.starters.context.configuration.TRpcConfigurationProperties;
import com.tencent.trpc.spring.boot.starters.test.SpringBootTestApplication;
import java.util.List;
import org.junit.Assert;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.context.SpringBootTest.WebEnvironment;
import org.springframework.test.context.ActiveProfiles;
import org.springframework.test.context.junit4.SpringRunner;

@RunWith(SpringRunner.class)
@SpringBootTest(classes = SpringBootTestApplication.class, webEnvironment = WebEnvironment.NONE)
@ActiveProfiles("bind-test1")
public class BindTest1 {
Expand All @@ -35,9 +32,9 @@ public class BindTest1 {
@Test
@SuppressWarnings("unchecked")
public void test() {
Assert.assertEquals(properties.getServer().getApp(), "TestApp");
Assertions.assertEquals(properties.getServer().getApp(), "TestApp");
List<Object> serviceList = (List<Object>) properties.getPlugins().getRegistry().get("polaris").get("service");
Assert.assertNotNull(serviceList);
Assert.assertEquals(serviceList.size(), 1);
Assertions.assertNotNull(serviceList);
Assertions.assertEquals(serviceList.size(), 1);
}
}
Loading
Loading