Examples of AssertionException


Examples of com.eviware.soapui.model.testsuite.AssertionException

            throws AssertionException {
        WadlDefinitionContext wadlContext = null;
        try {
            definitionContext = getWadlContext(messageExchange, context);
        } catch (Exception e1) {
            throw new AssertionException(new AssertionError(e1.getMessage()));
        }

        WadlValidator validator = new WadlValidator(wadlContext);

        try {
            AssertionError[] errors = validator.assertResponse(messageExchange);
            if (errors.length > 0) {
                throw new AssertionException(errors);
            }
        } catch (AssertionException e) {
            throw e;
        } catch (Exception e) {
            throw new AssertionException(new AssertionError(e.getMessage()));
        }

        return "Schema compliance OK";
    }
View Full Code Here

Examples of com.eviware.soapui.model.testsuite.AssertionException

            throws AssertionException {
        WsdlContext wsdlContext;
        try {
            wsdlContext = (WsdlContext) getWsdlContext(messageExchange, context);
        } catch (Exception e1) {
            throw new AssertionException(new AssertionError(e1.getMessage()));
        }

        WsdlValidator validator = new WsdlValidator(wsdlContext);

        try {
            AssertionError[] errors = validator.assertResponse(messageExchange, false);
            if (errors.length > 0) {
                throw new AssertionException(errors);
            }
        } catch (AssertionException e) {
            throw e;
        } catch (Exception e) {
            throw new AssertionException(new AssertionError(e.getMessage()));
        }

        return "Schema compliance OK";
    }
View Full Code Here

Examples of com.eviware.soapui.model.testsuite.AssertionException

            throws AssertionException {
        WsdlContext wsdlContext;
        try {
            wsdlContext = (WsdlContext) getWsdlContext((WsdlMessageExchange) messageExchange, context);
        } catch (Exception e1) {
            throw new AssertionException(new AssertionError(e1.getMessage()));
        }
        WsdlValidator validator = new WsdlValidator(wsdlContext);

        try {
            AssertionError[] errors = validator.assertRequest((WsdlMessageExchange) messageExchange, false);
            if (errors.length > 0) {
                throw new AssertionException(errors);
            }
        } catch (AssertionException e) {
            throw e;
        } catch (Exception e) {
            throw new AssertionException(new AssertionError(e.getMessage()));
        }

        return "Schema compliance OK";
    }
View Full Code Here

Examples of com.eviware.soapui.model.testsuite.AssertionException

                }
            }
        }
        String cumulativeError = cumulativeErrorMsg.toString();
        if (!StringUtils.isNullOrEmpty(cumulativeError)) {
            throw new AssertionException(new AssertionError(cumulativeError));
        }
    }
View Full Code Here

Examples of com.eviware.soapui.model.testsuite.AssertionException

            }
        }
        String cumulativeError = cumulativeErrorMsg.toString();
        if (!StringUtils.isNullOrEmpty(cumulativeError)) {
            throw new AssertionException(new AssertionError(cumulativeError));
        }
    }
View Full Code Here

Examples of com.eviware.soapui.model.testsuite.AssertionException

        } catch (Throwable e) {
            SoapUI.logError(e);
        }

        if (!messages.isEmpty()) {
            throw new AssertionException(assertionErrorList.toArray(new AssertionError[assertionErrorList.size()]));
        }

        return "OK";
    }
View Full Code Here

Examples of com.eviware.soapui.model.testsuite.AssertionException

        } catch (Throwable e) {
            SoapUI.logError(e);
        }

        if (!messages.isEmpty()) {
            throw new AssertionException(assertionErrorList.toArray(new AssertionError[assertionErrorList.size()]));
        }

        return "OK";
    }
View Full Code Here

Examples of com.eviware.soapui.model.testsuite.AssertionException

        if (statusElements.length >= 2) {
            String statusCode = statusElements[1].trim();
            if (!codeList.contains(statusCode)) {
                String message = "Response status code:" + statusCode + " is not in acceptable list of status codes";
                throw new AssertionException(new AssertionError(message));
            }
        } else {
            throw new AssertionException(new AssertionError("Status code extraction error! "));
        }

        return "OK";
    }
View Full Code Here

Examples of javolution.testing.AssertionException

    while (it.hasNext()) {
      String p = it.next();
      PartitionDesc desc = work.getPathToPartitionInfo().get(p);
      Map<String, String> spec = desc.getPartSpec();
      if (spec == null) {
        throw new AssertionException("No partition spec found in dynamic pruning");
      }

      String partValueString = spec.get(columnName);
      if (partValueString == null) {
        throw new AssertionException("Could not find partition value for column: " + columnName);
      }

      Object partValue = converter.convert(partValueString);
      if (LOG.isDebugEnabled()) {
        LOG.debug("Converted partition value: " + partValue + " original (" + partValueString + ")");
View Full Code Here

Examples of javolution.testing.AssertionException

    LOG.info("Source of event: " + sourceName);

    List<SourceInfo> infos = this.sourceInfoMap.get(sourceName);
    if (infos == null) {
      in.close();
      throw new AssertionException("no source info for event source: " + sourceName);
    }

    SourceInfo info = null;
    for (SourceInfo si : infos) {
      if (columnName.equals(si.columnName)) {
        info = si;
        break;
      }
    }

    if (info == null) {
      in.close();
      throw new AssertionException("no source info for column: " + columnName);
    }

    if (skip) {
      info.skipPruning.set(true);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.