Skip to content

Commit

Permalink
Temporarily disables tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
spencergibb committed Nov 22, 2021
1 parent d639552 commit e47a3a0
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 10 deletions.
Expand Up @@ -56,23 +56,24 @@ public class ConfigurationPropertiesRebinderListIntegrationTests {

@Test
@DirtiesContext
public void testAppendProperties() throws Exception {
then("[one, two]").isEqualTo(this.properties.getMessages().toString());
@Disabled("caused by https://github.com/spring-projects/spring-boot/issues/28776")
public void testAppendProperties() {
then(this.properties.getMessages()).containsOnly("one", "two");
TestPropertyValues.of("messages[0]:foo").applyTo(this.environment);
this.rebinder.rebind();
then(this.properties.getMessages().toString()).isEqualTo("[foo]");
then(this.properties.getMessages()).containsOnly("foo");
}

@Test
@DirtiesContext
@Disabled("Can't rebind to list and re-initialize it (need refresh scope for this to work)")
public void testReplaceProperties() throws Exception {
then("[one, two]").isEqualTo(this.properties.getMessages().toString());
public void testReplaceProperties() {
then(this.properties.getMessages()).containsOnly("one", "two");
Map<String, Object> map = findTestProperties();
map.clear();
TestPropertyValues.of("messages[0]:foo").applyTo(this.environment);
this.rebinder.rebind();
then(this.properties.getMessages().toString()).isEqualTo("[foo]");
then(this.properties.getMessages()).containsOnly("foo");
}

private Map<String, Object> findTestProperties() {
Expand All @@ -88,13 +89,13 @@ private Map<String, Object> findTestProperties() {

@Test
@DirtiesContext
public void testReplacePropertiesWithCommaSeparated() throws Exception {
then("[one, two]").isEqualTo(this.properties.getMessages().toString());
public void testReplacePropertiesWithCommaSeparated() {
then(this.properties.getMessages()).containsOnly("one", "two");
Map<String, Object> map = findTestProperties();
map.clear();
TestPropertyValues.of("messages:foo").applyTo(this.environment);
this.rebinder.rebind();
then(this.properties.getMessages().toString()).isEqualTo("[foo]");
then(this.properties.getMessages()).containsOnly("foo");
}

@Configuration(proxyBeanMethods = false)
Expand All @@ -103,7 +104,7 @@ public void testReplacePropertiesWithCommaSeparated() throws Exception {
protected static class TestConfiguration {

@Bean
protected TestProperties properties() {
protected TestProperties localTestProperties() {
return new TestProperties();
}

Expand Down
Expand Up @@ -21,6 +21,7 @@

import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;

import org.springframework.beans.factory.annotation.Autowired;
Expand Down Expand Up @@ -55,6 +56,7 @@ public class ConfigurationPropertiesRebinderProxyIntegrationTests {

@Test
@DirtiesContext
@Disabled("caused by https://github.com/spring-projects/spring-boot/issues/28776")
public void testAppendProperties() throws Exception {
// This comes out as a String not Integer if the rebinder processes the proxy
// instead of the target
Expand Down
Expand Up @@ -20,6 +20,7 @@
import java.util.List;
import java.util.Map;

import org.junit.jupiter.api.Disabled;
import org.junit.jupiter.api.Test;

import org.springframework.aop.framework.Advised;
Expand Down Expand Up @@ -56,6 +57,7 @@ public class RefreshScopeListBindingIntegrationTests {

@Test
@DirtiesContext
@Disabled("caused by https://github.com/spring-projects/spring-boot/issues/28776")
public void testAppendProperties() throws Exception {
then("[one, two]").isEqualTo(this.properties.getMessages().toString());
then(this.properties instanceof Advised).isTrue();
Expand Down

0 comments on commit e47a3a0

Please sign in to comment.