db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel John Debrunner <...@apache.org>
Subject Re: [junit]- ability to check JDBC level replaces _app properties files
Date Tue, 08 Aug 2006 14:35:04 GMT
Kristian Waagan wrote:

> The code is perfectly fine, but it can be reduced to:
> public static Test suite() {
>     TestSuite suite = new TestSuite(UpdateXXXTest.class);
>     // requires java.math.BigDecimal
>     if (JDBC.vmSupportsJDBC2())
>         suite.addTest(new UpdateXXXTest("jdbc2UpdateBigDecimal"));
>     return suite;
> }
> Note that the method requiring JDBC2 or higher was renamed.
> You might loose a bit of verbosity with this technique (which tests are
> added?), and maybe an extra look at the code is required to understand
> which methods are indeed test methods.
> Do people think this is an acceptable technique?

That's a great approach, it was a pain adding the cases individually and
I was concerned I might miss one, so your approach is much better.


View raw message