commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <>
Subject Re: [lang3] Test Fail in Headless Mode (at Least on a Mac)
Date Wed, 24 Nov 2010 11:51:39 GMT
On 24 November 2010 11:02, Stefan Bodewig <> wrote:
> On 2010-11-24, sebb wrote:
>> On 24 November 2010 09:46, Stefan Bodewig <> wrote:
>>> 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.
>> Or are those nodes running a frame buffer (I think that is the correct name)?
> I don't recall installing Xvfb (the X server running in a virtual frame
> buffer) but it could have been pulled in as a dependency - and I'm
> pretty sure we don't start it even if it is installed.  No, I don't
> think the builds have any X server to connect to.
>> Since there are headless hosts, maybe code which is supposed to be
>> able to run anywhere (e.g. LANG) needs to take this into account?
>> I.e. Perhaps MacGump has found a bug in Lang?
> The tests that failed are the ones for the event package.  I don't see
> any uses of AWT in the main code but the tests use AWT classes
> (ActionEvent and ActionListener).  It seems as if the static initializer
> of either class already requires a working window system on a Mac - it
> may not be required on OpenJDK's AWT.
> I don't think the lang3 code requires a window system - so no bug in the
> main code - but its tests do.

IMO the tests should then be fixed (I may have time to look later).

If there is a suitable alternative to the AWT events then use that,
otherwise allow for the test failure when running headless.

Seems to me it's more useful for Gump to point out these problems than
to try and hide them.

> Stefan
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message