@Test
public void shouldNotIncludeTheApplicationContextOnTheRootApplicationContextParamIfAlreadySet() throws Exception {

	ConfigurableWebApplicationContext ctx = mock(ConfigurableWebApplicationContext.class);
	when(servletContext.getAttributeNames()).thenReturn(enumeration(Collections.<String> emptyList()));
	when(servletContext.getAttribute(ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE)).thenReturn(ctx);
		
	defaultExpectations();
	
	SpringProvider provider = new SpringProvider();
	provider.start(servletContext);
	
	verify(servletContext, never()).setAttribute(eq(ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE), isA(WebApplicationContext.class));
}