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 C7CCD721D for ; Fri, 28 Oct 2011 11:52:52 +0000 (UTC) Received: (qmail 54339 invoked by uid 500); 28 Oct 2011 11:52:52 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 54321 invoked by uid 500); 28 Oct 2011 11:52:52 -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 54314 invoked by uid 99); 28 Oct 2011 11:52:52 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 28 Oct 2011 11:52:52 +0000 X-ASF-Spam-Status: No, hits=-2000.5 required=5.0 tests=ALL_TRUSTED,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; Fri, 28 Oct 2011 11:52:51 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 2DB19324DD9 for ; Fri, 28 Oct 2011 11:50:32 +0000 (UTC) Date: Fri, 28 Oct 2011 11:50:32 +0000 (UTC) From: "Kristian Waagan (Updated) (JIRA)" To: derby-dev@db.apache.org Message-ID: <316720315.30941.1319802632188.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <1978408321.8433.1319461172601.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Updated] (DERBY-5475) Formalize use of old Derby distributions in tests 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-5475?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Kristian Waagan updated DERBY-5475: ----------------------------------- Attachment: derby-5475-1a-DerbyVersion.diff Attaching patch 1a, which adds the following classes: o junit.DerbyVersion main class representing a Derby version. Has methods for comparing versions against each other. Holds major, minor, fixpack and point levels/versions. I decided to add all officially released versions as constants (code needing to use non-official/-released versions should create their constants elsewhere). The methods are inspired by existing use in the compatibility and the upgrade tests. A little more functionality may be added depending on what the UpgradeTrajectoryTest needs. There are a few version classes around (some as inner classes), hopefully this one can be used in all cases. o junit.DerbyVersionSimple Holds only major.minor levels. Introduced for compatibility, may be removed later on. o unitTests.junit.DerbyVersionTest Basic test for the comparison methods. Also added the new test to unitTests.junit._Suite. All the code is currently unused. The coming release repository will use it, so will the rewritten compatibility test (DERBY-2076). I will also make changes to the upgrade tests. Patch 1a ready for review. > Formalize use of old Derby distributions in tests > ------------------------------------------------- > > Key: DERBY-5475 > URL: https://issues.apache.org/jira/browse/DERBY-5475 > Project: Derby > Issue Type: Improvement > Components: Test > Affects Versions: 10.9.0.0 > Reporter: Kristian Waagan > Assignee: Kristian Waagan > Priority: Minor > Attachments: derby-5475-1a-DerbyVersion.diff > > > Some types of tests need old Derby distributions to perform the required actions. Currently this includes the upgrade test and the compatibility test. > Instead of each test dealing with this in their own way, there should be support for accessing old Derby distributions in the test framework. > I propose to add a Derby distribution repository in the test framework, with the following guidelines and changes: > o keep it as simple as possible, which suggests it is the users responsibility to keep the repository updated > o compatibility with the existing derbyTesting.oldReleasePath property > o make the tests requiring old distributions fail if there are no distributions available > o establish a default location where the test framework will look for old distributions if derbyTesting.oldReleasePath is unspecified > o the repository should not incur any costs when not used by the test(s) being run > In favor of simplicity the repository will not download releases itself. The user has to keep the repository contents up-to-date, which is as simple as running 'svn up' each time a new Derby release is published. It is unclear if, and what, the repository and/or relevant tests should do if the repository is outdated. It seems useful to allow the user to make available only a subset of the distributions, but maybe printing a warning is helpful to remind developers that their repository is stale. > Another related issue, which will only be relevant some time in the future, is whether a test framework of version X should make available distributions of version X+n. Currently I'm leaning towards not doing that, but haven't really looked into it. > See also thread on derby-dev: http://db.markmail.org/thread/44uyusa726cwjuk2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira