From dmitrys@earthlink.net Fri Sep 19 20:15:37 2003 Return-Path: Mailing-List: contact lucene-dev-help@jakarta.apache.org; run by ezmlm Delivered-To: mailing list lucene-dev@jakarta.apache.org Received: (qmail 54035 invoked from network); 19 Sep 2003 20:15:37 -0000 Received: from unknown (HELO host-65-125-35-13.larp.gov) (65.125.35.13) by daedalus.apache.org with SMTP; 19 Sep 2003 20:15:37 -0000 Received: from earthlink.net ([65.174.70.194]) by host-65-125-35-13.larp.gov (8.11.6/8.11.6) with ESMTP id h8JJIKn32186 for ; Fri, 19 Sep 2003 13:18:22 -0600 Message-ID: <3F6B652E.3030804@earthlink.net> Date: Fri, 19 Sep 2003 14:21:02 -0600 From: Dmitry Serebrennikov User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.3) Gecko/20030312 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Lucene Developers List Subject: How do we pass arguments to JUnit test cases? References: <30C0A13A-EA04-11D7-90CA-000393A564E6@ehatchersolutions.com> <3F6A01A8.6060604@earthlink.net> <3F6A14EB.40100@lucene.com> In-Reply-To: <3F6A14EB.40100@lucene.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N I'm trying to setup a JUnit test case that needs a file path in order to create an FSDirectory. (RAMDirectory is ok for some things, but I'd like to verify that the files are written correctly and can be read on subsequent runs of the program). Does Lucene have any standard policy for doing this in test cases? For example, I've seen people passing these kinds of things as System.properties. It can also be done relative to a working dir. Are there any test cases that already do this? Also, are there test cases that have pre-built datasets that they start with. For example, a test case that verifies backward compatibility could start by reading an index directory created by a previous version. One solution I've seen to this is to have a set of zip files checked into CVS that contain various test data sets. A test case then starts off by expanding one of these into some pre-determined directory and proceeds from there. Has anything like this been done before for Lucene? Thanks. Dmitry.