Return-Path: X-Original-To: apmail-db-derby-dev-archive@www.apache.org Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id CF6326419 for ; Tue, 28 Jun 2011 13:00:41 +0000 (UTC) Received: (qmail 15896 invoked by uid 500); 28 Jun 2011 13:00:41 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 15664 invoked by uid 500); 28 Jun 2011 13:00:40 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 15571 invoked by uid 99); 28 Jun 2011 13:00:39 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 28 Jun 2011 13:00:39 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 28 Jun 2011 13:00:38 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 947814365F7 for ; Tue, 28 Jun 2011 13:00:18 +0000 (UTC) Date: Tue, 28 Jun 2011 13:00:18 +0000 (UTC) From: "Kristian Waagan (JIRA)" To: derby-dev@db.apache.org Message-ID: <1775767861.1572.1309266018604.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <1222708960.20.1309216397146.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Updated] (DERBY-5300) Change derby.tests.trace to print the class as well as fixture name MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/DERBY-5300?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Kristian Waagan updated DERBY-5300: ----------------------------------- Attachment: derby-5090-2a-test.stat derby-5090-2a-test.diff derby-5090-1a-fix.stat derby-5090-1a-fix.diff Attaching patches 1a and 2a. Patch 1a is the fix, including some clean-up: * java/engine/org/apache/derby/impl/jdbc/EmbedResultSet.java Replace NewByteArrayInputStream with ByteArrayInputStream Wrap the above stream in CloseFilterInputStream * java/engine/org/apache/derby/iapi/services/io/CloseFilterInputStream.java Added filter stream that will throw exception after being closed. Modeled after the equally named class in the client. * java/engine/org/apache/derby/iapi/services/io/NewByteArrayInputStream.java Deleted this class, use a standard API-class instead. * java/engine/org/apache/derby/iapi/services/io/AccessibleByteArrayOutputStream.java Replace NewByteArrayInputStream with ByteArrayInputStream * java/client/org/apache/derby/client/am/ResultSet.java Renamed is_ to currentStream. Added instance variable currentReader Renamed method closeCloseFilterInputStream to closeOpenStreams Modified closeOpenStream to close both currentStream and currentReader (only one will be non-null at any time) Assigned reader to currentReader in getCharacterStream Patch 2b adds two tests, but I'm a bit unsure if I want to keep JDBCSetGet as a separate class. Will anyone else use it? If not, it might be better to keep them as private classes in the test class. If we want to add it as a JUnit utility class, should it be split in two, i.e. JDBCGet and JDBCSet? Also, if keeping I'd like to make it possible to obtain the name of the last called getter to improve the error reporting. Patches ready for review. > Change derby.tests.trace to print the class as well as fixture name > ------------------------------------------------------------------- > > Key: DERBY-5300 > URL: https://issues.apache.org/jira/browse/DERBY-5300 > Project: Derby > Issue Type: Improvement > Components: Test > Affects Versions: 10.9.0.0 > Reporter: Kathey Marsden > Priority: Trivial > Attachments: derby-5090-1a-fix.diff, derby-5090-1a-fix.stat, derby-5090-2a-test.diff, derby-5090-2a-test.stat, derby-5300-1a-print_jdbc_client.diff > > > I was thinking it would be good for the test output with -Dderby.tests.trace=true to have the class name as well as the fixture as I think if I had a nickel for every time I grepped for a fixture name to find out what class it is in, I would have a pretty big piggy bank. > It could print the full class name, like this: > org.apache.derbyTesting.functionTests.tests.lang.SimpleTest.testBasicOperations used 844 ms . > or strip off the org.apache.derbyTesting.functionTests for less output like: > tests.lang.SimpleTest.testBugFixes used 6265 ms . > Any preferences? -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira