Author: rsearls
Date: 2014-09-11 16:54:17 -0400 (Thu, 11 Sep 2014)
New Revision: 18934
Modified:
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsdd/WSDiscoveryTestCase.java
Log:
[bz-1012454] changed the order of checking for success.
Modified:
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsdd/WSDiscoveryTestCase.java
===================================================================
---
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsdd/WSDiscoveryTestCase.java 2014-09-11
18:38:55 UTC (rev 18933)
+++
stack/cxf/trunk/modules/testsuite/cxf-tests/src/test/java/org/jboss/test/ws/jaxws/samples/wsdd/WSDiscoveryTestCase.java 2014-09-11
20:54:17 UTC (rev 18934)
@@ -177,28 +177,11 @@
private void checkResolveMatches(List<ResolveMatchType> rmts, String address,
QName type) {
List<ResolveMatchType> rmtList = getByAddress(rmts, address);
- //assertTrue("Number of matches can not be 0.", (rmtList.size() >
0));
- assertEquals(dbgDumpList(rmtList), 1, rmtList.size());
- assertEquals(type, rmtList.get(0).getTypes().iterator().next());
- }
-
- // tmp method for debugging jenkins runs.
- // report uuid of the endpoint
- private String dbgDumpList(List<ResolveMatchType> rmtList){
- StringBuilder dbgStr = new StringBuilder().append("\n");
-
- if(rmtList.size() > 1){
- for(ResolveMatchType rmt: rmtList){
- String tmpStr = rmt.getEndpointReference().toString();
- int start = tmpStr.indexOf("<Address>");
- int end = tmpStr.indexOf("</Address>");
- if (start > -1 && end > -1){
- String uuidStr = tmpStr.substring(start+9, end);
- dbgStr.append(rmt.getXAddrs().get(0) +" " + uuidStr +
"\n");
- }
- }
+ if (rmtList.size() > 0) {
+ assertEquals(type, rmtList.get(0).getTypes().iterator().next());
+ } else {
+ assertTrue("Number of matches can not be 0.", (rmtList.size() >
0));
}
- return dbgStr.toString();
}
private List<ResolveMatchType> getByAddress(List<ResolveMatchType> rmts,
String address)