Sounds good to me... Do you have a patch for this that can be reviewed right now (obviously we want to hold off applying it until after the 0.20 branch is created).
-- Rob On 2 November 2012 10:29, Phil Harvey <[email protected]> wrote: > Hi, > > I would like us to upgrade Qpid's Java test to use JUnit 4 rather than > Junit 3. I believe this idea was floated a long time ago but never > progressed. > > My motivations are: > > - It opens the door to us replacing our bespoke test exclusion framework > with JUnit 4's Categories. This would allow each test to state which > category it's in (eg SlowTest or Amqp010Only), so that you can run the full > test suite specifying which Category(s) to include or exclude. Note that > it's hard to INclude a set of tests using our existing framework. > > - JUnit 4 bundles Hamcrest, which allows you to make more succinct and > readable assertions. > > - More succinct way of asserting that a specific exception was thrown > (@Test(expected=FooException.class) > > - assertEquals now supports arrays > > I have tried to do the upgrade and managed to get everything working. Note > that this requires a change to almost all of our test classes because the > JUnit 4 way of specifying a test is to use @Test rather than extending > TestCase. > > I propose that we do this upgrade in Qpid v0.22. Initially we would leave > our test exclusion framework as-is, migrating to use JUnit 4 Categories in > a separate piece of work. > > Would there be any objections to this? > > Phil >
