Browse Source

Suppress deprecation warning in Gradle build

See gh-22181
pull/22372/head
Sam Brannen 7 years ago
parent
commit
9bc2c99ce5
  1. 10
      src/test/java/org/springframework/core/env/PropertyPlaceholderConfigurerEnvironmentIntegrationTests.java

10
src/test/java/org/springframework/core/env/PropertyPlaceholderConfigurerEnvironmentIntegrationTests.java vendored

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-2014 the original author or authors.
* Copyright 2002-2019 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -19,19 +19,21 @@ package org.springframework.core.env; @@ -19,19 +19,21 @@ package org.springframework.core.env;
import static org.springframework.beans.factory.support.BeanDefinitionBuilder.rootBeanDefinition;
import org.junit.Test;
import org.springframework.beans.factory.config.PropertyPlaceholderConfigurer;
import org.springframework.context.support.GenericApplicationContext;
@SuppressWarnings("resource")
public class PropertyPlaceholderConfigurerEnvironmentIntegrationTests {
@Test
@SuppressWarnings("deprecation")
public void test() {
GenericApplicationContext ctx = new GenericApplicationContext();
ctx.registerBeanDefinition("ppc",
rootBeanDefinition(PropertyPlaceholderConfigurer.class)
rootBeanDefinition(org.springframework.beans.factory.config.PropertyPlaceholderConfigurer.class)
.addPropertyValue("searchSystemEnvironment", false)
.getBeanDefinition());
ctx.refresh();
ctx.getBean("ppc");
ctx.close();
}
}

Loading…
Cancel
Save