[Geoserver-devel] [jira] (GEOS-5386) Build failure in GWCIntegrationTest if second layer is cite:Geometryless

Ben Caradoc-Davies created BugGEOS-5386
Build failure in GWCIntegrationTest if second layer is cite:Geometryless

Issue Type:

BugBug

Affects Versions:

2.3-beta1

Assignee:

Gabriel Roldán

Components:

GWC

Created:

30/Oct/12 9:03 PM

Description:

At line 246, GWCIntegrationTest.testBasicIntegration arbitrarily chooses the second catalog layer for its “Basic get” test:

LayerInfo li = cat.getLayers().get(1);

On my laptop, this fails in both Maven and Eclipse:

Tests in error: 
  testBasicIntegration(org.geoserver.gwc.GWCIntegrationTest): Thread 1 Unknown layer cite:Geometryless. Check the logfiles, it may not have loaded properly.

org.geowebcache.GeoWebCacheException: Thread 1 Unknown layer cite:Geometryless. Check the logfiles, it may not have loaded properly.
	at org.geowebcache.layer.TileLayerDispatcher.getTileLayer(TileLayerDispatcher.java:102)
	at org.geoserver.gwc.GWCIntegrationTest.testBasicIntegration(GWCIntegrationTest.java:249)

I suspect the problem is that the order of layers is determined by filesystem order, which varies between machines. If you are unlucky, the second layer is cite:Geometryless, which, being geometryless, appears to have no tile layer, causing the test to fail. Changing the selection of the layer to the first or third makes the test pass (for me).

I suggest one of two solutions:

(1) Pick a non-geometryless layer by name and test that one, or

(2) Filter out geometryless layers and test all the others.

Either approach will fix build stability.

Environment:

Apache Maven 3.0.4 (r1232337; 2012-01-17 16:44:56+0800)
Maven home: /home/car605/junk/java/maven3
Java version: 1.6.0_37, vendor: Sun Microsystems Inc.
Java home: /home/car605/junk/java/jdk1.6.0_37.x64/jre
Default locale: en_GB, platform encoding: UTF-8
OS name: “linux”, version: “3.2.0-4-amd64”, arch: “amd64”, family: “unix”

Project:

GeoServer

Priority:

CriticalCritical

Reporter:

Ben Caradoc-Davies

This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your [JIRA administrators](https://jira.codehaus.org/secure/ContactAdministrators!default.jspa). For more information on JIRA, see: [http://www.atlassian.com/software/jira](http://www.atlassian.com/software/jira)