/** prints stack trace of assertion error and nested exception * @param err PrintWriter where to print stack trace */ public void printStackTrace(PrintWriter err) { synchronized (err) { super.printStackTrace(err); err.println("\nNested Exception is:"); nestedException.printStackTrace(err); } }
/** prints stack trace of assertion error and nested exception * @param err PrintStream where to print stack trace */ public void printStackTrace(PrintStream err) { synchronized (err) { super.printStackTrace(err); err.println("\nNested Exception is:"); nestedException.printStackTrace(err); } } }
@Override public synchronized void addFailure(final Test test, final AssertionFailedError assertionFailedError) { // throw new RuntimeException(assertionFailedError.getMessage()); assertionFailedError.printStackTrace(); } };
@Override public synchronized void addFailure(final Test test, final AssertionFailedError assertionFailedError) { // throw new RuntimeException(assertionFailedError.getMessage()); assertionFailedError.printStackTrace(); } };
@Override public synchronized void addFailure(final Test test, final AssertionFailedError assertionFailedError) { // throw new RuntimeException(assertionFailedError.getMessage()); assertionFailedError.printStackTrace(); } };
public void addFailure(Test test, AssertionFailedError t) { StringBuffer sb = new StringBuffer(); sb.append(test.toString()); sb.append("\n"); StringWriter sw = new StringWriter(); t.printStackTrace(new PrintWriter(sw, true)); sb.append(sw.toString()); Log.getLogWriter().severe("zzzzzFAILURE IN " + test, t); //reportFailure(test, sb.toString()); lastFailClass = getClassName(test); lastFailMethod = getMethodName(test); lastThrowable = t; }
public void addFailure(Test test, AssertionFailedError t) { StringBuffer sb = new StringBuffer(); sb.append(test.toString()); sb.append("\n"); StringWriter sw = new StringWriter(); t.printStackTrace(new PrintWriter(sw, true)); sb.append(sw.toString()); failureMessages.append(sb); log.severe("\nTEST " + test + " FAILURE", t); Log.getLogWriter().severe("FAILURE IN " + test, t); reportFailure(test, sb.toString()); lastFail = getClassName(test); } }
public void printStackTrace(PrintWriter s) { synchronized (s) { super.printStackTrace(s); if (cause != null) { s.println("Root cause"); cause.printStackTrace(s); } } }
result.failure.printStackTrace(new PrintWriter(writer)); writer.write(" </failure>");
public void printStackTrace(PrintStream s) { synchronized (s) { super.printStackTrace(s); if (cause != null) { s.println("Root cause"); cause.printStackTrace(s); } } }
public void printStackTrace() { super.printStackTrace(); if (cause != null) { System.out.println("Root cause"); cause.printStackTrace(); } } }
protected void validate(URI ivorn, Node resource) throws ServletException { Element resElem; NodeList nl; if(resource.getNodeType() == org.w3c.dom.Node.DOCUMENT_NODE) { System.out.println("doc from validate in RegistrarServlet = " + DomHelper.DocumentToString((Document)resource) ); resElem = ((Document)resource).getDocumentElement(); }else if(resource.getNodeType() == org.w3c.dom.Node.ELEMENT_NODE) { System.out.println("element from validate in RegistrarServlet = " + DomHelper.ElementToString((Element)resource) ); resElem = (Element)resource; }else { throw new ServletException("Cound not validate document, the registration is not a type understood to validate."); } try { System.out.println("validating local name = " + resElem.getLocalName()); RegistryValidator.isValid(resElem,resElem.getLocalName()); }catch(AssertionFailedError afe) { afe.printStackTrace(); log.error("Error invalid document = " + afe.getMessage()); throw new ServletException("Invalid update, document not valid " + afe.getMessage()); }//catch }
afe.printStackTrace(); validateSingleResources = true; log.warn("Error invalid document = " + afe.getMessage());
@Override public void addFailure(Test test, AssertionFailedError t) { getWriter().println("*** Failed: " + ((BaseWebScriptTest)test).getName()); t.printStackTrace(getWriter()); }
@Test public void test1() throws Exception { CompilerAssert<File, File> compiler = compiler("plugin.shiro.require.duplicate1"); try { compiler.assertCompile(); } catch (AssertionFailedError e) { e.printStackTrace(); } }
@Test public void test2() throws Exception { CompilerAssert<File, File> compiler = compiler("plugin.shiro.require.duplicate2"); try { compiler.assertCompile(); } catch (AssertionFailedError e) { e.printStackTrace(); } }
afe.printStackTrace(); log.error("Error invalid document = " + afe.getMessage()); throw new SOAPFaultException("Server Error: " + "Invalid update, document not valid ","Server Error: " + "Invalid update, document not valid " + afe.getMessage(), adminwsdlNS, SOAPFaultException.ADMINSOAP_TYPE);