URL Cleanup - Fix broken tests

See gh-22669
This commit is contained in:
Sam Brannen
2019-03-27 12:57:02 +01:00
parent c51a257210
commit 20f1f46ae1
4 changed files with 10 additions and 10 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2018 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.
@@ -224,8 +224,8 @@ public class HandlersBeanDefinitionParserTests {
List<HandshakeInterceptor> interceptors = transportService.getHandshakeInterceptors();
assertThat(interceptors, contains(instanceOf(OriginHandshakeInterceptor.class)));
assertTrue(transportService.shouldSuppressCors());
assertTrue(transportService.getAllowedOrigins().contains("http://mydomain1.com"));
assertTrue(transportService.getAllowedOrigins().contains("http://mydomain2.com"));
assertTrue(transportService.getAllowedOrigins().contains("https://mydomain1.com"));
assertTrue(transportService.getAllowedOrigins().contains("https://mydomain2.com"));
}

View File

@@ -184,8 +184,8 @@ public class MessageBrokerBeanDefinitionParserTests {
interceptors = defaultSockJsService.getHandshakeInterceptors();
assertThat(interceptors, contains(instanceOf(FooTestInterceptor.class),
instanceOf(BarTestInterceptor.class), instanceOf(OriginHandshakeInterceptor.class)));
assertTrue(defaultSockJsService.getAllowedOrigins().contains("http://mydomain3.com"));
assertTrue(defaultSockJsService.getAllowedOrigins().contains("http://mydomain4.com"));
assertTrue(defaultSockJsService.getAllowedOrigins().contains("https://mydomain3.com"));
assertTrue(defaultSockJsService.getAllowedOrigins().contains("https://mydomain4.com"));
SimpUserRegistry userRegistry = this.appContext.getBean(SimpUserRegistry.class);
assertNotNull(userRegistry);