Hi Kenneth, issue is JUnit 5 is not JUnit 4 +1, it is another project (like TestNG is) so migration is not even an option. My goal in the PR was to enable people using JUnit 5 as a base framework to test beam pipelines and be able to reuse all their tooling goodness like this extension https://talend.github.io/component-runtime/documentation-testing.html#_configuring_environments or any extension allowing to start a server before running tests. I tried to mitigate the changes to keep it very familiar for a JUnit 4 user.
In terms of usage you have an example at https://github.com/rmannibucau/incubator-beam/blob/e61c650d57738206f3d02d949181074afccb87bb/sdks/java/core/src/test/java/org/apache/beam/sdk/testing/junit5/WithApacheBeamCustomRunnerTest.java#L42 It is aligned on the way JUnit 5 designs its extensions. The rule equivalent was just introduced in JUnit this week but reuses this extension mecanism, it just allows to instantiate it manually in a static field instead of using the meta annotation which keep the extension of this PR valuable. Romain Manni-Bucau @rmannibucau <https://twitter.com/rmannibucau> | Blog <https://rmannibucau.metawerx.net/> | Old Blog <http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> | LinkedIn <https://www.linkedin.com/in/rmannibucau> 2018-01-23 16:52 GMT+01:00 Kenneth Knowles <[email protected]>: > As open source, IMO it is fine to do something just because you are > interested, as long as it works in the interest of the project. I'm not > opposed, but there isn't enough information yet. > > I would like to see a design document about the differences between JUnit > 4 and 5 and how that will affect Beam (examples: @Rule and @Runner changes) > and maybe some information about how JUnit 5 is being received by other > projects. Generally, mentioned also on the "automatic parameters for IOs" > thread, sizable changes with implications for the project should be > preceded by design documents to gather feedback from the community. > > Incidentally, scanning the PR, I see things that looks like they aren't > just the JUnit 4 to 5 migration. You should narrow the focus to just the > migration. > > Kenn > > On Tue, Jan 23, 2018 at 1:41 AM, Jean-Baptiste Onofré <[email protected]> > wrote: > >> Great, thanks ! >> >> We will resume our review here once Beam 2.3.0 is out. >> >> Regards >> JB >> >> On 01/23/2018 10:28 AM, Romain Manni-Bucau wrote: >> > Oki JB, >> > >> > Will implement it on my side until beam supports it then. >> > >> > Thanks for the feedback. >> > >> > >> > Romain Manni-Bucau >> > @rmannibucau <https://twitter.com/rmannibucau> | Blog >> > <https://rmannibucau.metawerx.net/> | Old Blog >> > <http://rmannibucau.wordpress.com> | Github < >> https://github.com/rmannibucau> | >> > LinkedIn <https://www.linkedin.com/in/rmannibucau> >> > >> > 2018-01-23 10:24 GMT+01:00 Jean-Baptiste Onofré <[email protected] >> > <mailto:[email protected]>>: >> > >> > Hi Romain, >> > >> > Definitely it's not something targeted for Beam 2.3.0. >> > >> > It's interesting, but it sounds a bit like a lonesome cowboy effort. >> > >> > I think it would have been great to discuss a bit in term of >> priority (on the >> > mailing list) before rushing on the PR. Couple of highlights in the >> Jira or PR >> > would be appreciated too. >> > >> > So, please, keep the PR open, I will take a look asap. >> > >> > Regards >> > JB >> > >> > On 01/23/2018 09:40 AM, Romain Manni-Bucau wrote: >> > > Hi guys, >> > > >> > > Anyone able to have a look to the JUnit 5 PR >> > > (https://github.com/apache/beam/pull/4360 >> > <https://github.com/apache/beam/pull/4360>)? >> > > >> > > Worse case a "yes we'll move this direction" or "no we don't care >> about JUnit 5 >> > > for now" feedback would be very valuable for me. >> > > >> > > Thanks, >> > > Romain Manni-Bucau >> > > @rmannibucau <https://twitter.com/rmannibucau >> > <https://twitter.com/rmannibucau>> | Blog >> > > <https://rmannibucau.metawerx.net/ <https://rmannibucau.metawerx. >> net/>> | >> > Old Blog >> > > <http://rmannibucau.wordpress.com <http://rmannibucau.wordpress. >> com>> >> > | Github <https://github.com/rmannibucau < >> https://github.com/rmannibucau>> | >> > > LinkedIn <https://www.linkedin.com/in/rmannibucau >> > <https://www.linkedin.com/in/rmannibucau>> >> > >> > -- >> > Jean-Baptiste Onofré >> > [email protected] <mailto:[email protected]> >> > http://blog.nanthrax.net >> > Talend - http://www.talend.com >> > >> > >> >> -- >> Jean-Baptiste Onofré >> [email protected] >> http://blog.nanthrax.net >> Talend - http://www.talend.com >> > >
