Re: Adding @NonParameterized
Marius Kruger <[email protected]> Thu, 14 Jul 2011 21:29:27 +0200
| Newsgroups | gmane.comp.java.junit.devel |
|---|---|
| Message-ID | <CADkRGrwThTG7QbRvM0yK_HpfrEUT2M=RpWJoSun10O67C4MKfw@mail.gmail.com> |
--===============9097653275533979273== Content-Type: multipart/alternative; boundary=20cf30780e484fccc304a80c8ebd --20cf30780e484fccc304a80c8ebd Content-Type: text/plain; charset=UTF-8 On 27 June 2011 17:40, David Saff <[email protected]> wrote: > Good point. > > Here's how I'm thinking about moving forward: we currently have @Rule, > which provides a way to override the rules for _running_ a method, for > _every @Test_ method in the class. I'm considering a similar > construct, which will allow overriding: > > 1) Which methods trigger tests > 2) How many tests per method > 3) Validation of test methods > 4) Test-instance creation > 5) Test-method invoking > > Given this, it should be possible to enable something very close to > @NonParameterized as a drop-in Rule-like object, rather than as a core > modification to the overall Parameterized runner. > It's a bit abstract for me, I can not imagine/picture how my use case will look like with this. With the above features it sounds like it will be quite useful. If you like you can make a sudo example to show how you imagine it to be used. > One issue: I can't think of a name for this new construct. Suggestions > welcome. > @TestController @TestOrchestrator @TestManager One problem that I noticed with @RunWith(JUnitParamsRunner.class) tests is that IDE support lags a bit or maybe its a bug, but from eclipse I can't re-run a single method or one of it's permutations or jump to its location by double-clicking on it in the junit panel. It works fine with @RunWith(value = Parameterized.class) which I'm glad to see. Before I knew about this, I made my own suite implementation to sort of do this, and with some tweaking I was able to get eclipse to be able to re-run those too. -- <>< Marius ><> --20cf30780e484fccc304a80c8ebd Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 27 June 2011 17:40, David Saff <span dir=3D"ltr"><<a href=3D"mailto:d= [email protected]">[email protected]</a>></span> wrote:<br><div class=3D"gmail_= quote"><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-= left:1px #ccc solid;padding-left:1ex;"> Good point.<br> <br> Here's how I'm thinking about moving forward: we currently have @Ru= le,<br> which provides a way to override the rules for _running_ a method, for<br> _every @Test_ method in the class. =C2=A0I'm considering a similar<br> construct, which will allow overriding:<br> <br> 1) Which methods trigger tests<br> 2) How many tests per method<br> 3) Validation of test methods<br> 4) Test-instance creation<br> 5) Test-method invoking<br> <br> Given this, it should be possible to enable something very close to<br> @NonParameterized as a drop-in Rule-like object, rather than as a core<br> modification to the overall Parameterized runner.<br></blockquote><div><br>= </div><div>It's a bit abstract for me, I can not imagine/picture how my= use case will look like with this. With the above features it sounds like = it will be quite useful.=C2=A0</div> <div>If you like you can make a sudo example to show how you imagine it to = be used.</div><div>=C2=A0</div><blockquote class=3D"gmail_quote" style=3D"m= argin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"> One issue: I can't think of a name for this new construct. =C2=A0Sugges= tions welcome.<font class=3D"Apple-style-span" color=3D"#888888"><br></font= ></blockquote><div><br></div><div>@TestController</div><div>@TestOrchestrat= or</div> <div>@TestManager</div><div>=C2=A0</div><div><br></div><div>One problem tha= t I noticed with @RunWith(JUnitParamsRunner.class) tests is that=C2=A0</div= ><div>IDE support lags a bit or maybe its a bug, but from eclipse I can'= ;t re-run a single method or one of it's permutations or jump to its lo= cation by double-clicking on it in the junit panel. It works fine with=C2= =A0@RunWith(value =3D Parameterized.class) which I'm glad to see.</div> <div>Before I knew about this, I made my own suite implementation to sort o= f do this,=C2=A0</div><div>and with some tweaking I was able to get eclipse= to be able to re-run those too.</div><div><br></div></div>-- <br><>&= lt; Marius ><><br> <br> --20cf30780e484fccc304a80c8ebd-- --===============9097653275533979273== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------------ AppSumo Presents a FREE Video for the SourceForge Community by Eric Ries, the creator of the Lean Startup Methodology on "Lean Startup Secrets Revealed." This video shows you how to validate your ideas, optimize your ideas and identify your business strategy. http://p.sf.net/sfu/appsumosfdev2dev --===============9097653275533979273== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Junit-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/junit-devel --===============9097653275533979273==--