Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

URLResourceProvider does not behave consistently for servlet and non-servlet containers #216

Open
mkouba opened this issue Oct 1, 2019 · 1 comment

Comments

@mkouba
Copy link
Contributor

mkouba commented Oct 1, 2019

Issue Overview

An injected @ArquillianResource URL ends with a slash for servlet containers but does not end with a slash for non-servlet containers. See also org.jboss.arquillian.container.spi.client.protocol.metadata.Servlet.getBaseURIAsString() and org.jboss.arquillian.container.test.impl.enricher.resource.URLResourceProvider.toURL(HTTPContext) - only the host and port is used here and so no slash is added to the URL.

Expected Behaviour

The behavior should be identical for both use cases. It would probably make sense to always add a slash, e.g. url + "myResource" and not url + "/myResource. Also most Arquillian adapters are servlet-based.

@starksm64
Copy link
Member

It is easy enough to add this behavior by adding a rootContext to the HttpContext, but the question is, should it default to "/" or null and keep the current behavior?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants