Package de.juplo.httpresources
Class HttpResourceProtocolResolverIT
- java.lang.Object
-
- de.juplo.httpresources.IntegrationTestBase
-
- de.juplo.httpresources.HttpResourceProtocolResolverIT
-
@SpringBootTest({"juplo.http-resources.protocol-resolver.enabled=true","juplo.http-resources.resolver.enabled=false","juplo.http-resources.resolver.exclusion-patterns=**.txt"}) public class HttpResourceProtocolResolverIT extends IntegrationTestBase
Mostly identically withHttpResourceResolverIT
. Differences:Test explicit lookup with full address through context and has no exclusion/inclusion.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
HttpResourceProtocolResolverIT.Application
-
Nested classes/interfaces inherited from class de.juplo.httpresources.IntegrationTestBase
IntegrationTestBase.Callback, IntegrationTestBase.ClockStub, IntegrationTestBase.IntegrationTestConfiguration
-
-
Field Summary
-
Fields inherited from class de.juplo.httpresources.IntegrationTestBase
CLOCK, formatter, NGINX, server
-
-
Constructor Summary
Constructors Constructor Description HttpResourceProtocolResolverIT()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
setUp()
void
testCachingOfExisting()
void
testCachingOfNonExistent()
void
testFetchExistent()
void
testFetchNonExistent()
void
testModifiedResource()
void
testResourceHandling()
Olthough the is not enabled in this test-scenario, this works nearly, identically to the same test there, because all lookups for resources in the resource-chain for static http-resources are executed through the application-context, where theHttpResourceProtocolResolver
is registerd.-
Methods inherited from class de.juplo.httpresources.IntegrationTestBase
address, clearMockServer, FETCH, getMockServerPort, getMockServerUri, INTERNAL_SERVER_ERROR, NGINIX_IP, NGINX, NGINX, NGINX_PORT, NGINX_URI, NOT_FOUND, prepareMockServer, RESPONSE
-
-
-
-
Method Detail
-
setUp
@BeforeEach public void setUp()
-
testResourceHandling
@Test public void testResourceHandling() throws Exception
Olthough the is not enabled in this test-scenario, this works nearly, identically to the same test there, because all lookups for resources in the resource-chain for static http-resources are executed through the application-context, where theHttpResourceProtocolResolver
is registerd. Only exclusion is not working, since this is only implemented in the .- Throws:
Exception
-
testCachingOfNonExistent
@Test public void testCachingOfNonExistent() throws Exception
- Throws:
Exception
-
-