Re: can I change junit runner main class

2004-02-11 Thread Mariano Benitez
I am facing an issue extending CommandlineJava, there are some methods and attributes that are private, they are: getActualVMCommand() sysproperties haveBootClasspath haveClasspath bootclasspath javacommand vmcommand I will create accessor for the attributes and make the private methods protecte

Re: can I change junit runner main class

2004-02-11 Thread Stefan Bodewig
On Wed, 11 Feb 2004, Mariano Benitez <[EMAIL PROTECTED]> wrote: > ultimately you could replace direct usages of the commandline > variable by an accessor, so I just need to override the > accessor. Sounds like the cleanest solution. > I could upload a patch to bugzilla if you need to, but the ch

Re: can I change junit runner main class

2004-02-11 Thread Mariano Benitez
This sounds simple to do inside the task, simply change private CommandlineJava commandline = new CommandlineJava(); to private CommandlineJava commandline = newCommandlineJava(); with protected CommandlineJava newCommandlineJava() { return new CommandlineJava(); } basically

Re: can I change junit runner main class

2004-02-11 Thread Stefan Bodewig
On Tue, 10 Feb 2004, Mariano Benitez <[EMAIL PROTECTED]> wrote: > another option would be to let people extend CommandLineJava and > overwrite the method getCommandLine() to change the arguments, so I > can customize my command line while you maintain the contract of > JUnitRunner. This sounds si

Re: can I change junit runner main class

2004-02-11 Thread Stefan Bodewig
On Tue, 10 Feb 2004, Dominique Devienne <[EMAIL PROTECTED]> wrote: > The solution would be to make the Ant test runner public and > extensible, so that people that need to extend it, for example to > run all the tests in a single forked VM That wouldn't work as it is the task that invokes the run

Re: can I change junit runner main class

2004-02-10 Thread Mariano Benitez
another option would be to let people extend CommandLineJava and overwrite the method getCommandLine() to change the arguments, so I can customize my command line while you maintain the contract of JUnitRunner. I think I will move in this direction since not only I need to change the main class

Re: can I change junit runner main class

2004-02-10 Thread Mariano Benitez
I assume that your class understands all the command line arguments Ant's testrunner uses and passes them along. How would your class deal with new arguments we add? My class is just a bootstrap that do some classloading stuff regarding my application and then invokes the main class (JUnitRun

RE: can I change junit runner main class

2004-02-10 Thread Dominique Devienne
> From: Stefan Bodewig [mailto:[EMAIL PROTECTED] > On Mon, 09 Feb 2004, Mariano Benitez <[EMAIL PROTECTED]> wrote: > > The problem is that I cannot simulate this using JUnit with > > fork, because I cannot change the main class and use mine > > instead. > > I assume that your class und

Re: can I change junit runner main class

2004-02-10 Thread Stefan Bodewig
On Mon, 09 Feb 2004, Mariano Benitez <[EMAIL PROTECTED]> wrote: > The problem is that I cannot simulate this using JUnit with > fork, because I cannot change the main class and use mine > instead. I assume that your class understands all the command line arguments Ant's testrunner use