The problem is a bit more complexe as Selenium RC Server uses Jetty 5.x

In fact I only need to automatically run Selenium Server when my application, 
and I need to run Jetty 6 server before my test cases. I'm using a JUnit 
TestSetup to run Jetty 6 only one time, and it works fine. If I run manually 
Selenium Server in another JVN, it works fine.

But as soon as I try to put Selenium Server in my pom as a dependency, I get 
errors at runtime.

In fact, I would like Maven download selenium server in order to always have 
correct version, but I don't really need it in the classpath, as I can run 
something like execute("java -jar 
$M2_HOME/repository/org/openqa/selenium/server/selenium-server-XX.jar");

Do you know if it's possible ?

----- Message d'origine ----
De : Lee Meador <[EMAIL PROTECTED]>
À : Maven Users List <[email protected]>; Julien HENRY <[EMAIL PROTECTED]>
Envoyé le : Jeudi, 21 Septembre 2006, 7h17mn 30s
Objet : Re: Problem with conflicting classes in classpath

If Selenium RC Server will run with Jetty 6 you may be able to add an
exclusion to your dependency on Selenium. Here is an example from a pom of
mine:

            <dependency>
                <groupId>jmock</groupId>
                <artifactId>jmock-cglib</artifactId>
                <version>1.0.1</version>
                <scope>test</scope>
                <exclusions>
                    <exclusion>
                        <groupId>cglib</groupId>
                        <artifactId>cglib-full</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>

Now, this is "test" but the principle is the same. I need JMock (cglib) in
my application but I don't want cglib-full so I exclude it. What I want is
cglib-nodep BTW so I have to add that dependency in myself.

Some other messages recently have noted that there are sometimes issues
related to exclusions in Maven 2.0.4 for which fixes exist but are not
released.

-- Lee


On 9/21/06, Julien HENRY <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> I have a conflict with 2 versions of Jetty. The first one is a dependency
> of Selenium RC Server (Jetty 5x), and I'm using Jetty 6 for my tests. As
> soon as I add the Selenium Server dependency in my pom, I get strange error.
>
> How can I solve this issue ?
>
> Thanks
>
> Julien
>
>
>


-- 
-- Lee Meador
Sent from gmail. My real email address is lee AT leemeador.com




Reply via email to