|
|
@ -1,7 +1,7 @@
|
|
|
|
/*
|
|
|
|
/*
|
|
|
|
* Tencent is pleased to support the open source community by making Spring Cloud Tencent available.
|
|
|
|
* Tencent is pleased to support the open source community by making spring-cloud-tencent available.
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* Copyright (C) 2019 THL A29 Limited, a Tencent company. All rights reserved.
|
|
|
|
* Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* Licensed under the BSD 3-Clause License (the "License");
|
|
|
|
* Licensed under the BSD 3-Clause License (the "License");
|
|
|
|
* you may not use this file except in compliance with the License.
|
|
|
|
* you may not use this file except in compliance with the License.
|
|
|
@ -57,6 +57,7 @@ import static org.assertj.core.api.Assertions.assertThat;
|
|
|
|
@ExtendWith(MockitoExtension.class)
|
|
|
|
@ExtendWith(MockitoExtension.class)
|
|
|
|
public class ReactivePolarisCircuitBreakerTest {
|
|
|
|
public class ReactivePolarisCircuitBreakerTest {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private static MockedStatic<ApplicationContextAwareUtils> mockedApplicationContextAwareUtils;
|
|
|
|
private final ApplicationContextRunner reactiveContextRunner = new ApplicationContextRunner()
|
|
|
|
private final ApplicationContextRunner reactiveContextRunner = new ApplicationContextRunner()
|
|
|
|
.withConfiguration(AutoConfigurations.of(
|
|
|
|
.withConfiguration(AutoConfigurations.of(
|
|
|
|
PolarisContextAutoConfiguration.class,
|
|
|
|
PolarisContextAutoConfiguration.class,
|
|
|
@ -66,8 +67,6 @@ public class ReactivePolarisCircuitBreakerTest {
|
|
|
|
.withPropertyValues("spring.cloud.polaris.circuitbreaker.enabled=true")
|
|
|
|
.withPropertyValues("spring.cloud.polaris.circuitbreaker.enabled=true")
|
|
|
|
.withPropertyValues("spring.cloud.polaris.circuitbreaker.configuration-cleanup-interval=5000");
|
|
|
|
.withPropertyValues("spring.cloud.polaris.circuitbreaker.configuration-cleanup-interval=5000");
|
|
|
|
|
|
|
|
|
|
|
|
private static MockedStatic<ApplicationContextAwareUtils> mockedApplicationContextAwareUtils;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@BeforeAll
|
|
|
|
@BeforeAll
|
|
|
|
public static void beforeClass() {
|
|
|
|
public static void beforeClass() {
|
|
|
|
mockedApplicationContextAwareUtils = Mockito.mockStatic(ApplicationContextAwareUtils.class);
|
|
|
|
mockedApplicationContextAwareUtils = Mockito.mockStatic(ApplicationContextAwareUtils.class);
|
|
|
|