Rename *Test.java -> *Tests.java

Rename a few test classes that accidentally ended in `Test` instead of
`Tests`.

Issue gh-8945
This commit is contained in:
Phillip Webb 2020-08-05 17:24:50 -07:00 committed by Rob Winch
parent 94cf4d1de7
commit 27ac046d8a
21 changed files with 25 additions and 25 deletions

View File

@ -37,7 +37,7 @@ import static org.mockito.BDDMockito.given;
* @author paulwheeler * @author paulwheeler
*/ */
@RunWith(MockitoJUnitRunner.class) @RunWith(MockitoJUnitRunner.class)
public class AclClassIdUtilsTest { public class AclClassIdUtilsTests {
private static final Long DEFAULT_IDENTIFIER = 999L; private static final Long DEFAULT_IDENTIFIER = 999L;
private static final BigInteger BIGINT_IDENTIFIER = new BigInteger("999"); private static final BigInteger BIGINT_IDENTIFIER = new BigInteger("999");

View File

@ -24,7 +24,7 @@ import org.springframework.security.core.authority.mapping.SimpleAuthorityMapper
import static org.assertj.core.api.Assertions.assertThat; import static org.assertj.core.api.Assertions.assertThat;
public class LdapAuthenticationProviderConfigurerTest { public class LdapAuthenticationProviderConfigurerTests {
private LdapAuthenticationProviderConfigurer<AuthenticationManagerBuilder> configurer; private LdapAuthenticationProviderConfigurer<AuthenticationManagerBuilder> configurer;

View File

@ -30,7 +30,7 @@ import static org.assertj.core.api.Assertions.assertThat;
* *
* @author Eleftheria Stein * @author Eleftheria Stein
*/ */
public class ServerHttpSecurityConfigurationTest { public class ServerHttpSecurityConfigurationTests {
@Rule @Rule
public final SpringTestRule spring = new SpringTestRule(); public final SpringTestRule spring = new SpringTestRule();

View File

@ -35,7 +35,7 @@ import static org.assertj.core.api.AssertionsForClassTypes.assertThatThrownBy;
* @since 5.0 * @since 5.0
*/ */
@RunWith(MockitoJUnitRunner.class) @RunWith(MockitoJUnitRunner.class)
public class UserDetailsResourceFactoryBeanTest { public class UserDetailsResourceFactoryBeanTests {
@Mock @Mock
ResourceLoader resourceLoader; ResourceLoader resourceLoader;

View File

@ -95,16 +95,16 @@ public class FormLoginConfigTests {
.param("username", "user") .param("username", "user")
.param("password", "password") .param("password", "password")
.with(csrf())) .with(csrf()))
.andExpect(redirectedUrl(WebConfigUtilsTest.URL + "/default")); .andExpect(redirectedUrl(WebConfigUtilsTests.URL + "/default"));
this.mvc.perform(post("/login") this.mvc.perform(post("/login")
.param("username", "user") .param("username", "user")
.param("password", "wrong") .param("password", "wrong")
.with(csrf())) .with(csrf()))
.andExpect(redirectedUrl(WebConfigUtilsTest.URL + "/failure")); .andExpect(redirectedUrl(WebConfigUtilsTests.URL + "/failure"));
this.mvc.perform(get("/")) this.mvc.perform(get("/"))
.andExpect(redirectedUrl("http://localhost" + WebConfigUtilsTest.URL + "/login")); .andExpect(redirectedUrl("http://localhost" + WebConfigUtilsTests.URL + "/login"));
} }
@Test @Test

View File

@ -26,7 +26,7 @@ import org.springframework.beans.factory.xml.ParserContext;
@RunWith(PowerMockRunner.class) @RunWith(PowerMockRunner.class)
@PrepareOnlyThisForTest(ParserContext.class) @PrepareOnlyThisForTest(ParserContext.class)
public class WebConfigUtilsTest { public class WebConfigUtilsTests {
public final static String URL = "/url"; public final static String URL = "/url";
@Mock @Mock

View File

@ -20,7 +20,7 @@ import org.springframework.beans.factory.support.BeanDefinitionRegistry;
import org.springframework.beans.factory.support.GenericBeanDefinition; import org.springframework.beans.factory.support.GenericBeanDefinition;
import org.springframework.beans.factory.support.SimpleBeanDefinitionRegistry; import org.springframework.beans.factory.support.SimpleBeanDefinitionRegistry;
public class MessageSecurityPostProcessorTest { public class MessageSecurityPostProcessorTests {
private WebSocketMessageBrokerSecurityBeanDefinitionParser.MessageSecurityPostProcessor postProcessor = private WebSocketMessageBrokerSecurityBeanDefinitionParser.MessageSecurityPostProcessor postProcessor =
new WebSocketMessageBrokerSecurityBeanDefinitionParser.MessageSecurityPostProcessor("id", false); new WebSocketMessageBrokerSecurityBeanDefinitionParser.MessageSecurityPostProcessor("id", false);

View File

@ -27,9 +27,9 @@
<http auto-config="true" use-expressions="false"> <http auto-config="true" use-expressions="false">
<intercept-url pattern="/**" access="ROLE_USER"/> <intercept-url pattern="/**" access="ROLE_USER"/>
<form-login <form-login
default-target-url="#{T(org.springframework.security.config.http.WebConfigUtilsTest).URL}/default" default-target-url="#{T(org.springframework.security.config.http.WebConfigUtilsTests).URL}/default"
authentication-failure-url="#{T(org.springframework.security.config.http.WebConfigUtilsTest).URL}/failure" authentication-failure-url="#{T(org.springframework.security.config.http.WebConfigUtilsTests).URL}/failure"
login-page="#{T(org.springframework.security.config.http.WebConfigUtilsTest).URL}/login"/> login-page="#{T(org.springframework.security.config.http.WebConfigUtilsTests).URL}/login"/>
</http> </http>
<b:import resource="userservice.xml"/> <b:import resource="userservice.xml"/>

View File

@ -32,7 +32,7 @@ import org.springframework.core.convert.converter.Converter;
/** /**
* Tests for {@link RsaKeyConverters} * Tests for {@link RsaKeyConverters}
*/ */
public class RsaKeyConvertersTest { public class RsaKeyConvertersTests {
private static final String PKCS8_PRIVATE_KEY = "-----BEGIN PRIVATE KEY-----\n" + private static final String PKCS8_PRIVATE_KEY = "-----BEGIN PRIVATE KEY-----\n" +
"MIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQCMk7CKSTfu3QoV\n" + "MIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQCMk7CKSTfu3QoV\n" +
"HoPVXxwZO+qweztd36cVWYqGOZinrOR2crWFu50AgR2CsdIH0+cqo7F4Vx7/3O8i\n" + "HoPVXxwZO+qweztd36cVWYqGOZinrOR2crWFu50AgR2CsdIH0+cqo7F4Vx7/3O8i\n" +

View File

@ -27,7 +27,7 @@ import org.springframework.security.crypto.encrypt.AesBytesEncryptor.CipherAlgor
import org.springframework.security.crypto.keygen.BytesKeyGenerator; import org.springframework.security.crypto.keygen.BytesKeyGenerator;
import org.springframework.security.crypto.keygen.KeyGenerators; import org.springframework.security.crypto.keygen.KeyGenerators;
public class BouncyCastleAesBytesEncryptorEquivalencyTest { public class BouncyCastleAesBytesEncryptorEquivalencyTests {
private byte[] testData; private byte[] testData;
private String password; private String password;

View File

@ -25,7 +25,7 @@ import org.junit.Test;
import org.springframework.security.crypto.codec.Hex; import org.springframework.security.crypto.codec.Hex;
import org.springframework.security.crypto.keygen.KeyGenerators; import org.springframework.security.crypto.keygen.KeyGenerators;
public class BouncyCastleAesBytesEncryptorTest { public class BouncyCastleAesBytesEncryptorTests {
private byte[] testData; private byte[] testData;
private String password; private String password;

View File

@ -29,7 +29,7 @@ import org.mockito.junit.MockitoJUnitRunner;
import org.springframework.messaging.Message; import org.springframework.messaging.Message;
@RunWith(MockitoJUnitRunner.class) @RunWith(MockitoJUnitRunner.class)
public class AndMessageMatcherTest { public class AndMessageMatcherTests {
@Mock @Mock
private MessageMatcher<Object> delegate; private MessageMatcher<Object> delegate;

View File

@ -29,7 +29,7 @@ import org.mockito.junit.MockitoJUnitRunner;
import org.springframework.messaging.Message; import org.springframework.messaging.Message;
@RunWith(MockitoJUnitRunner.class) @RunWith(MockitoJUnitRunner.class)
public class OrMessageMatcherTest { public class OrMessageMatcherTests {
@Mock @Mock
private MessageMatcher<Object> delegate; private MessageMatcher<Object> delegate;

View File

@ -42,7 +42,7 @@ import static org.assertj.core.api.Assertions.assertThatThrownBy;
* @author Rafiullah Hamedy * @author Rafiullah Hamedy
* @since 5.1 * @since 5.1
*/ */
public class ClientRegistrationsTest { public class ClientRegistrationsTests {
/** /**
* Contains all optional parameters that are found in ClientRegistration * Contains all optional parameters that are found in ClientRegistration

View File

@ -47,7 +47,7 @@ import static org.mockito.Mockito.when;
* @since 5.1 * @since 5.1
*/ */
@RunWith(MockitoJUnitRunner.class) @RunWith(MockitoJUnitRunner.class)
public class ServerOAuth2AuthorizationCodeAuthenticationTokenConverterTest { public class ServerOAuth2AuthorizationCodeAuthenticationTokenConverterTests {
@Mock @Mock
private ReactiveClientRegistrationRepository clientRegistrationRepository; private ReactiveClientRegistrationRepository clientRegistrationRepository;

View File

@ -32,7 +32,7 @@ import org.springframework.security.oauth2.core.OAuth2RefreshToken;
* *
* @author Nikita Konev * @author Nikita Konev
*/ */
public class MapOAuth2AccessTokenResponseConverterTest { public class MapOAuth2AccessTokenResponseConverterTests {
private MapOAuth2AccessTokenResponseConverter messageConverter; private MapOAuth2AccessTokenResponseConverter messageConverter;

View File

@ -31,7 +31,7 @@ import org.springframework.security.oauth2.core.OAuth2AccessToken;
* *
* @author Nikita Konev * @author Nikita Konev
*/ */
public class OAuth2AccessTokenResponseMapConverterTest { public class OAuth2AccessTokenResponseMapConverterTests {
private OAuth2AccessTokenResponseMapConverter messageConverter; private OAuth2AccessTokenResponseMapConverter messageConverter;

View File

@ -37,7 +37,7 @@ import static org.mockito.Mockito.when;
* @author Rob Winch * @author Rob Winch
*/ */
@RunWith(MockitoJUnitRunner.class) @RunWith(MockitoJUnitRunner.class)
public class PayloadExchangeMatcherReactiveAuthorizationManagerTest { public class PayloadExchangeMatcherReactiveAuthorizationManagerTests {
@Mock @Mock
private ReactiveAuthorizationManager<PayloadExchangeAuthorizationContext> authz; private ReactiveAuthorizationManager<PayloadExchangeAuthorizationContext> authz;

View File

@ -39,7 +39,7 @@ import static org.springframework.security.saml2.provider.service.registration.T
/** /**
* Tests for {@link Saml2MetadataFilter} * Tests for {@link Saml2MetadataFilter}
*/ */
public class Saml2MetadataFilterTest { public class Saml2MetadataFilterTests {
RelyingPartyRegistrationRepository repository; RelyingPartyRegistrationRepository repository;
Saml2MetadataResolver resolver; Saml2MetadataResolver resolver;

View File

@ -48,7 +48,7 @@ import org.springframework.test.util.ReflectionTestUtils;
*/ */
@RunWith(PowerMockRunner.class) @RunWith(PowerMockRunner.class)
@PrepareOnlyThisForTest(Logger.class) @PrepareOnlyThisForTest(Logger.class)
public class DebugFilterTest { public class DebugFilterTests {
@Captor @Captor
private ArgumentCaptor<HttpServletRequest> requestCaptor; private ArgumentCaptor<HttpServletRequest> requestCaptor;
@Captor @Captor

View File

@ -39,7 +39,7 @@ import static org.mockito.Mockito.when;
* @author Alexey Nesterov * @author Alexey Nesterov
* @since 5.2 * @since 5.2
*/ */
public class ReactivePreAuthenticatedAuthenticationManagerTest { public class ReactivePreAuthenticatedAuthenticationManagerTests {
private ReactiveUserDetailsService mockUserDetailsService private ReactiveUserDetailsService mockUserDetailsService
= mock(ReactiveUserDetailsService.class); = mock(ReactiveUserDetailsService.class);