This is the mail archive of the mauve-discuss@sourceware.cygnus.com mailing list for the Mauve project. See the Mauve home page for more information.
Some test cases may require support classes (ie. resource bundles for ResourceBundle tests). This patch ensures that they are built. Does this look ok? --- cut here ------------------------------------------------------------ Index: ChangeLog =================================================================== RCS file: /cvs/mauve/mauve/ChangeLog,v retrieving revision 1.27 diff -u -r1.27 ChangeLog --- ChangeLog 1998/12/04 16:06:55 1.27 +++ ChangeLog 1998/12/05 22:15:31 @@ -1,3 +1,8 @@ +1998-12-05 Anthony Green <green@cygnus.com> + + * choose: Add support for "Uses" magic comment. + * README: Updated to mention Uses. + 1998-12-04 Tom Tromey <tromey@cygnus.com> * choose: Allow tag file to appear in build directory. @@ -65,7 +70,6 @@ * choose: Recognize `libjava' tag. ->>>>>>> 1.22 1998-12-01 Anthony Green <green@cygnus.com> * gnu/testlet/java/lang/Double/new_Double.java: New file. @@ -166,7 +170,6 @@ process from stdin. * choose: New file. ->>>>>>> 1.16 1998-11-25 Tom Tromey <tromey@cygnus.com> * README: New file. Index: README =================================================================== RCS file: /cvs/mauve/mauve/README,v retrieving revision 1.10 diff -u -r1.10 README --- README 1998/12/04 11:45:03 1.10 +++ README 1998/12/05 22:15:32 @@ -116,6 +116,17 @@ ================================================================ +Some test cases may require extra utility classes to run. When the +choose script selects a test case for running, the framework +identifies the supporting classes through another magic comment in the +test source. + +Support classes must all appear on a single line beginning with the +string "// Uses: ". The framework assumes that all utility classes +used are found in that same package as the test case. + +================================================================ + You'll notice that each test has a public constructor. This probably seems strange -- why not have the `test' method be static, and just call it? Index: choose =================================================================== RCS file: /cvs/mauve/mauve/choose,v retrieving revision 1.11 diff -u -r1.11 choose --- choose 1998/12/04 16:06:56 1.11 +++ choose 1998/12/05 22:15:33 @@ -172,6 +172,15 @@ if test "$istest" = yes; then echo $class >> $classes test -n "$verbose" && echo "Chose $class" + + # Now that we know we're going to use this class, see + # what other support classes this test requires. + useslist=" `grep '^// Uses:' gnu/testlet/$file | sed -e 's,^// Uses:,,'` " + for used in $useslist; do + usedfile=`dirname $file`/$used.java + echo -n " gnu/testlet/$usedfile" >> $choices + done + fi fi done --- cut here ------------------------------------------------------------ AG -- Anthony Green Cygnus Solutions Sunnyvale, California