Return-Path: X-Original-To: apmail-ant-notifications-archive@minotaur.apache.org Delivered-To: apmail-ant-notifications-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id DC05511229 for ; Fri, 2 May 2014 17:00:28 +0000 (UTC) Received: (qmail 12862 invoked by uid 500); 2 May 2014 17:00:24 -0000 Delivered-To: apmail-ant-notifications-archive@ant.apache.org Received: (qmail 12736 invoked by uid 500); 2 May 2014 17:00:21 -0000 Mailing-List: contact notifications-help@ant.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@ant.apache.org Delivered-To: mailing list notifications@ant.apache.org Received: (qmail 12648 invoked by uid 99); 2 May 2014 17:00:18 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 May 2014 17:00:18 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 May 2014 17:00:17 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 40374238889B for ; Fri, 2 May 2014 16:59:57 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1591973 - /ant/antlibs/antunit/trunk/src/main/org/apache/ant/antunit/LogCapturer.java Date: Fri, 02 May 2014 16:59:57 -0000 To: notifications@ant.apache.org From: bodewig@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20140502165957.40374238889B@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: bodewig Date: Fri May 2 16:59:56 2014 New Revision: 1591973 URL: http://svn.apache.org/r1591973 Log: dry things up a little Modified: ant/antlibs/antunit/trunk/src/main/org/apache/ant/antunit/LogCapturer.java Modified: ant/antlibs/antunit/trunk/src/main/org/apache/ant/antunit/LogCapturer.java URL: http://svn.apache.org/viewvc/ant/antlibs/antunit/trunk/src/main/org/apache/ant/antunit/LogCapturer.java?rev=1591973&r1=1591972&r2=1591973&view=diff ============================================================================== --- ant/antlibs/antunit/trunk/src/main/org/apache/ant/antunit/LogCapturer.java (original) +++ ant/antlibs/antunit/trunk/src/main/org/apache/ant/antunit/LogCapturer.java Fri May 2 16:59:56 2014 @@ -120,19 +120,23 @@ public class LogCapturer implements Buil */ public void messageLogged(BuildEvent event) { if (event.getPriority() <= Project.MSG_ERR) { - err.append(event.getMessage()).append(StringUtils.LINE_SEP); + append(err, event); } if (event.getPriority() <= Project.MSG_WARN) { - warn.append(event.getMessage()).append(StringUtils.LINE_SEP); + append(warn, event); } if (event.getPriority() <= Project.MSG_INFO) { - info.append(event.getMessage()).append(StringUtils.LINE_SEP); + append(info, event); } if (event.getPriority() <= Project.MSG_VERBOSE) { - verbose.append(event.getMessage()).append(StringUtils.LINE_SEP); + append(verbose, event); } if (event.getPriority() <= Project.MSG_DEBUG) { - debug.append(event.getMessage()).append(StringUtils.LINE_SEP); + append(debug, event); } } + + private static void append(StringBuffer sb, BuildEvent event) { + sb.append(event.getMessage()).append(StringUtils.LINE_SEP); + } }