On 2010-11-22, Jörg Schaible wrote:

> Stefan Bodewig wrote:

>> The commons-lang3 builds fail[2] and too me it looks as if this was
>> because AWT is not running in headless mode,

confirmed by passing -DargLine=-Djava.awt.headless=true to mvn - the
builds now pass.

>> I am suprised the problem doesn't show up in the other CI builds.

Still surprised 8-)

It doesn't show up inside Gump on Linux or FreeBSD running OpenJDK or
the FreeBSD port of Sun's VM either - maybe this codebase's AWT detects
there is no X-Server and switches to headless mode without any help.

>> There likely is a way we could set additional properties for the maven
>> run (like surefire specific system properties or telling it not to
>> fork), but (a) this is beyond my Maven foo and (b) would have to be
>> repeated in other environments that have the same problem as well.  Does
>> anybody know of a better fix?

> a) is:

>         <plugin>
>           <groupId>org.apache.maven.plugins</groupId>
>           <artifactId>maven-surefire-plugin</artifactId>
>           <configuration>
>             <forkMode>once</forkMode><!-- at least once -->
>             <systemProperties>
>               <property>
>                 <name>java.awt.headless</name>
>                 <value>true</value>
>               </property>
>             </systemProperties>
>           </configuration>
>         </plugin>

Which would mean I'd have to modify the POM.  Gump shouldn't do that and
I don't feel I should fiddle with the POMs of projects that I'm not an
active developer of.

Setting surefire's argLine will help Gump but will become tiresome if it
happens for more than one project.

> the question is if it should be added to the parent for all commons in
> general or as a setting for lang only?

I'm pretty sure there are other commons components who's tests will use
parts of AWT so I'd be +1 on putting it into the parent.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org
For additional commands, e-mail: dev-h...@commons.apache.org

Reply via email to