소스 검색

Fix TestingAuthenticationTokenTests JDK 1.6 compile

Issue: gh-5097
Rob Winch 7 년 전
부모
커밋
4cad151b57
1개의 변경된 파일2개의 추가작업 그리고 1개의 파일을 삭제
  1. 2 1
      core/src/test/java/org/springframework/security/authentication/TestingAuthenticationTokenTests.java

+ 2 - 1
core/src/test/java/org/springframework/security/authentication/TestingAuthenticationTokenTests.java

@@ -16,6 +16,7 @@
 package org.springframework.security.authentication;
 
 import org.junit.Test;
+import org.springframework.security.core.GrantedAuthority;
 import org.springframework.security.core.authority.SimpleGrantedAuthority;
 
 import java.util.Arrays;
@@ -46,7 +47,7 @@ public class TestingAuthenticationTokenTests {
 	public void constructorWhenCollectionAuthoritiesThenAuthenticated() {
 		TestingAuthenticationToken authenticated =
 			new TestingAuthenticationToken("principal", "credentials",
-				Arrays.asList(new SimpleGrantedAuthority("authority")));
+				Arrays.<GrantedAuthority>asList(new SimpleGrantedAuthority("authority")));
 
 		assertThat(authenticated.isAuthenticated()).isTrue();
 	}