15
15
*/
16
16
package org .springframework .security .integration ;
17
17
18
- import static org .assertj .core .api .Assertions .assertThat ;
19
- import static org .hamcrest .CoreMatchers .containsString ;
20
- import static org .springframework .security .test .web .servlet .request .SecurityMockMvcRequestPostProcessors .csrf ;
21
- import static org .springframework .security .test .web .servlet .response .SecurityMockMvcResultMatchers .authenticated ;
22
- import static org .springframework .test .web .servlet .request .MockMvcRequestBuilders .get ;
23
- import static org .springframework .test .web .servlet .request .MockMvcRequestBuilders .post ;
24
- import static org .springframework .test .web .servlet .result .MockMvcResultMatchers .content ;
25
- import static org .springframework .test .web .servlet .result .MockMvcResultMatchers .redirectedUrl ;
26
- import static org .springframework .test .web .servlet .result .MockMvcResultMatchers .status ;
27
-
28
18
import java .util .Collections ;
29
19
import java .util .List ;
30
20
31
21
import org .junit .Test ;
22
+
32
23
import org .springframework .mock .web .MockHttpSession ;
33
24
import org .springframework .security .core .context .SecurityContext ;
34
25
import org .springframework .security .core .session .SessionDestroyedEvent ;
35
26
import org .springframework .test .web .servlet .MockMvc ;
36
27
import org .springframework .test .web .servlet .request .MockHttpServletRequestBuilder ;
37
28
29
+ import static org .assertj .core .api .Assertions .assertThat ;
30
+ import static org .hamcrest .CoreMatchers .containsString ;
31
+ import static org .springframework .security .test .web .servlet .request .SecurityMockMvcRequestPostProcessors .csrf ;
32
+ import static org .springframework .security .test .web .servlet .response .SecurityMockMvcResultMatchers .authenticated ;
33
+ import static org .springframework .test .web .servlet .request .MockMvcRequestBuilders .get ;
34
+ import static org .springframework .test .web .servlet .request .MockMvcRequestBuilders .post ;
35
+ import static org .springframework .test .web .servlet .result .MockMvcResultMatchers .content ;
36
+ import static org .springframework .test .web .servlet .result .MockMvcResultMatchers .redirectedUrl ;
37
+ import static org .springframework .test .web .servlet .result .MockMvcResultMatchers .status ;
38
+
38
39
/**
39
40
* @author Luke Taylor
40
41
*/
@@ -47,7 +48,7 @@ public void maxConcurrentLoginsValueIsRespected() throws Exception {
47
48
48
49
MockMvc mockMvc = createMockMvc ("classpath:/spring/http-security-concurrency.xml" , "classpath:/spring/in-memory-provider.xml" , "classpath:/spring/testapp-servlet.xml" );
49
50
50
- mockMvc .perform (get ("secure/index" ).session (session1 ))
51
+ mockMvc .perform (get ("/ secure/index" ).session (session1 ))
51
52
.andExpect (status ().is3xxRedirection ());
52
53
53
54
MockHttpServletRequestBuilder login1 = login ()
0 commit comments