maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Craig McClanahan" <>
Subject Re: test vs provided dependency scopes
Date Thu, 14 Dec 2006 19:28:49 GMT
On 12/14/06, Guillaume Duchesneau <> wrote:
> Hello,
> I am having problems setting my project dependencies.  I have a JAR
> project that needs javax.servlet/servlet-api/2.4.  My first idea was to
> set its scope to provided since this jar will end up in a servlet
> container and the servlet api will be provided by the container.  The
> problem I have is that my JUnits needs this dependency to run too.  So I
> would need both provided and test scopes for that dependency.  But I do
> not see any way to tell that the Maven.  Am I missing something?
> Anybody can help?

In my experience, dependencies that you mark "provided" (as you should do
with something like the servlet API) are automatically added to the test
classpath as well.


> Guillaume

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message