Mass changes to various projects under Ant umbrella - should we be doing it?

classic Classic list List threaded Threaded
27 messages Options
12
Reply | Threaded
Open this post in threaded view
|

Mass changes to various projects under Ant umbrella - should we be doing it?

Jaikiran Pai
I don't mean to appear authoritative but I feel that these mass,
never-ending changes to various projects under the Ant umbrella, related
to formatting, coding style, whitespaces, syntax changes and such aren't
really worth it. Especially when a lot of those changes are merely, IMO,
personal preferences, to code that has been around for a long time now.
It's extremely hard to do any kind of review for such changes and IMO
they really don't add any value. I can understand if the changes are
being done in specific section when a bug or feature involves that
specific area of code, but a lot of these commits aren't of that nature.

I haven't been long around in the project, to have any kind of authority
on this matter, but having been involved in some other open source
projects, changes like these aren't really good nor are typically
considered required or accepted.

Could we please reconsider whether or not we should be doing such changes?

-Jaikiran


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Gintautas Grigelionis
I sense a personal attack using broad, generalised accusations :-)
Could we please stop the inflammatory comments and be more to the point?

Yes, I did make a series of commits, but it's not endless. In fact, it is
to end pretty soon.
It is long merely because each commit is about a specific pattern
(sometimes applied to a specific part of code), so it is easier to follow.
Sometimes the commits are iterative, cleaning up or building upon previous
changes.
Java is a language with the syntax that changes and tries to accomodate new
patterns that make programming more efficient.
We should try to use these patterns everywhere because uniformity aids
comprehension. Old code is not a golden code, it's a rotten code.
If I slip up and propose something that's not up to snuff, I'll gladly
revert that -- and hopefully learn something in the process.
If it is of interest, I would gladly explain what kind of patterns I was
looking for.

Gintas

P.S.: A shoutout to Jan who encouraged to dig deeper on Ivy PR#31.

2018-04-07 5:41 GMT+00:00 Jaikiran Pai <[hidden email]>:

> I don't mean to appear authoritative but I feel that these mass,
> never-ending changes to various projects under the Ant umbrella, related to
> formatting, coding style, whitespaces, syntax changes and such aren't
> really worth it. Especially when a lot of those changes are merely, IMO,
> personal preferences, to code that has been around for a long time now.
> It's extremely hard to do any kind of review for such changes and IMO they
> really don't add any value. I can understand if the changes are being done
> in specific section when a bug or feature involves that specific area of
> code, but a lot of these commits aren't of that nature.
>
> I haven't been long around in the project, to have any kind of authority
> on this matter, but having been involved in some other open source
> projects, changes like these aren't really good nor are typically
> considered required or accepted.
>
> Could we please reconsider whether or not we should be doing such changes?
>
> -Jaikiran
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Stefan Bodewig
In reply to this post by Jaikiran Pai
On 2018-04-07, Jaikiran Pai wrote:

> I don't mean to appear authoritative but I feel that these mass,
> never-ending changes to various projects under the Ant umbrella,
> related to formatting, coding style, whitespaces, syntax changes and
> such aren't really worth it.

We've done some systematic changes in the past, usually when a certain
pattern has lead to bugs and we wanted to ensure the pattern was
eliminated systematically. There are some precendents around
try-with-resources or the introduction of generics that were similar to
Gintas' series of commits, but there've only been a few.

We did have one big "cleanup" commit which has been the one that brought
us the regressions in 1.10.2 and I deeply regret not taking the time
reviewing the change back then.

> Especially when a lot of those changes are merely, IMO, personal
> preferences, to code that has been around for a long time now.

> It's extremely hard to do any kind of review for such changes and IMO
> they really don't add any value.

Some of them certainly are personal preferences. I tend to agree that
many of the latest changes are not really improving the code base.

I'm about twenty commits behind on reviewing the changes.

> I haven't been long around in the project, to have any kind of
> authority on this matter, but having been involved in some other open
> source projects, changes like these aren't really good nor are
> typically considered required or accepted.

You've got as much authority as anybody else of us to state you don't
like the changes or as Gintas has stating they make to code base
cleaner.

Honestly, I would prefer to not make this type of change at the scale
they have happened. Mostly because I feel I'm spending a lot of time
reviewing changes that transform working code into equivalent working
code. Not reviewig the changes is not an option.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Stefan Bodewig
In reply to this post by Gintautas Grigelionis
On 2018-04-07, Gintautas Grigelionis wrote:

> Java is a language with the syntax that changes and tries to accomodate new
> patterns that make programming more efficient.

Some of the patterns you've been changign don't fall into this category
for me. Switching if/else blocks, colapsing ifs or removing parens from
longer boolean expressions because you happend to remember && binds
stronger than || is not something that makes reading and understanding
the code more efficient IMHO

Code is read far more often than written - this is probably even more
true for open source code. If we wanted to optimize then my vote would
go to optimize for readablity and clarity. I'm not saying the existing
code is readable. Readability certainly is highly subjective, as is
"efficient programming".

> We should try to use these patterns everywhere because uniformity aids
> comprehension.

Here we have to agree that we disagree. Small diffs are more important
than uniformity to me.

> Old code is not a golden code, it's a rotten code.

Now it is my turn to feel offended. Our old code certainly is not
golden. I certainly have written (and every day write) bad code, but
I've never written rotten code.

I don't believe woking well tested code rots. Code rot is something that
happends when code doesn't get adapted to changing environments or
requirements. This is not the case here.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Nicolas Lalevée
In reply to this post by Gintautas Grigelionis
Le 7 avr. 2018 à 14:13, Gintautas Grigelionis <[hidden email]> a écrit :
>
> I sense a personal attack using broad, generalised accusations :-)
> Could we please stop the inflammatory comments and be more to the point?

Please don’t. Nothing is personal here. Jaikiran used « we ». Even if you are the author of the majority of the patches, people are reviewing it, people are finding errors and fixing them afterwards, this is a community effort. Thus this is a community discussion.

I have not been reading ant-dev lately, so I cannot comment much about the last patches. For a while now I have not been involved much, but probably the last reviews of patches bored me enough so I lost track of the dev community entirely.

Nicolas


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Gintautas Grigelionis
2018-04-09 16:48 GMT+00:00 Nicolas Lalevée <[hidden email]>:

> I have not been reading ant-dev lately, so I cannot comment much about the
> last patches. For a while now I have not been involved much, but probably
> the last reviews of patches bored me enough so I lost track of the dev
> community entirely.
>
> Nicolas
>

Sorry for being boring; glad to have you back.

Gintas
Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Gintautas Grigelionis
In reply to this post by Stefan Bodewig
2018-04-08 16:13 GMT+00:00 Stefan Bodewig <[hidden email]>:

> On 2018-04-07, Gintautas Grigelionis wrote:
>
> > Java is a language with the syntax that changes and tries to accomodate
> new
> > patterns that make programming more efficient.
>
> Some of the patterns you've been changign don't fall into this category
> for me. Switching if/else blocks, colapsing ifs or removing parens from
> longer boolean expressions because you happend to remember && binds
> stronger than || is not something that makes reading and understanding
> the code more efficient IMHO
>
> Code is read far more often than written - this is probably even more
> true for open source code. If we wanted to optimize then my vote would
> go to optimize for readablity and clarity. I'm not saying the existing
> code is readable. Readability certainly is highly subjective, as is
> "efficient programming".
>

Agreed.


> > We should try to use these patterns everywhere because uniformity aids
> > comprehension.
>
> Here we have to agree that we disagree. Small diffs are more important
> than uniformity to me.
>

Agreed.

> Old code is not a golden code, it's a rotten code.
>
> Now it is my turn to feel offended. Our old code certainly is not
> golden. I certainly have written (and every day write) bad code, but
> I've never written rotten code.
>

Sorry for the slip.


> I don't believe woking well tested code rots. Code rot is something that
> happends when code doesn't get adapted to changing environments or
> requirements. This is not the case here.


I wrote earlier that I was about to review the unit tests.
I was particularly unhappy about the root-property hack for an ancient
deficiency in Surefire.
I consider my previous commits a sort of a groundwork for refactorisation
of JUnit tests.
Would you bear with me if I commit the changes to the tests? Given the
previous discussion, I would accept a "no".

Gintas
Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Nicolas Lalevée
In reply to this post by Gintautas Grigelionis


> Le 9 avr. 2018 à 20:46, Gintautas Grigelionis <[hidden email]> a écrit :
>
> 2018-04-09 16:48 GMT+00:00 Nicolas Lalevée <[hidden email]>:
>
>> I have not been reading ant-dev lately, so I cannot comment much about the
>> last patches. For a while now I have not been involved much, but probably
>> the last reviews of patches bored me enough so I lost track of the dev
>> community entirely.
>>
>> Nicolas
>>
>
> Sorry for being boring

Again, it is not you. It is the « code cleaning ». And there is always boring stuff to do. We are discussing here how much we can handle, as a community.

Nicolas


---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Jaikiran Pai
In reply to this post by Gintautas Grigelionis

On 10/04/18 12:27 AM, Gintautas Grigelionis wrote:
> 2018-04-08 16:13 GMT+00:00 Stefan Bodewig <[hidden email]>:
>
>> I don't believe woking well tested code rots. Code rot is something that
>> happends when code doesn't get adapted to changing environments or
>> requirements. This is not the case here.
>
> I wrote earlier that I was about to review the unit tests.
> I was particularly unhappy about the root-property hack for an ancient
> deficiency in Surefire.
I checked some of the mail discussions, but couldn't find any relevant
details about this. Can you explain what the root-property hack is? I
also don't understand how Surefire is related to our tests, which are
run using the junit and ant-unit framework. If I missed some previous
discussion, please pointme to it and I'll read up on that.

> I consider my previous commits a sort of a groundwork for refactorisation
> of JUnit tests.
Considering the commits that have been made (even just considering only
the Ant ones), I don't see how those relate to some plan to refactor
JUnit tests.

-Jaikiran

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Stefan Bodewig
In reply to this post by Gintautas Grigelionis
On 2018-04-09, Gintautas Grigelionis wrote:

> I was particularly unhappy about the root-property hack for an ancient
> deficiency in Surefire.

Could you please expand on this a bit?

> I consider my previous commits a sort of a groundwork for
> refactorisation of JUnit tests.  Would you bear with me if I commit
> the changes to the tests?

I hope you are aware the classes that end up in ant-testutil.jar build a
public API.

To be honest I don't exactly recall what kind of refactorings you
intended, so maybe the easiest way to gather feedback is a pull request
in this case.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

mbenson
In reply to this post by Stefan Bodewig
On Sun, Apr 8, 2018, 11:03 AM Stefan Bodewig <[hidden email]> wrote:

> On 2018-04-07, Jaikiran Pai wrote:
>
> > I don't mean to appear authoritative but I feel that these mass,
> > never-ending changes to various projects under the Ant umbrella,
> > related to formatting, coding style, whitespaces, syntax changes and
> > such aren't really worth it.
>
> We've done some systematic changes in the past, usually when a certain
> pattern has lead to bugs and we wanted to ensure the pattern was
> eliminated systematically. There are some precendents around
> try-with-resources or the introduction of generics that were similar to
> Gintas' series of commits, but there've only been a few.
>
> We did have one big "cleanup" commit which has been the one that brought
> us the regressions in 1.10.2 and I deeply regret not taking the time
> reviewing the change back then.
>
>
I'm pretty sure I was the perpetrator of said commit and wanted to offer my
apologies.

Matt


>
> > Especially when a lot of those changes are merely, IMO, personal
> > preferences, to code that has been around for a long time now.
>
> > It's extremely hard to do any kind of review for such changes and IMO
> > they really don't add any value.
>
> Some of them certainly are personal preferences. I tend to agree that
> many of the latest changes are not really improving the code base.
>
> I'm about twenty commits behind on reviewing the changes.
>
> > I haven't been long around in the project, to have any kind of
> > authority on this matter, but having been involved in some other open
> > source projects, changes like these aren't really good nor are
> > typically considered required or accepted.
>
> You've got as much authority as anybody else of us to state you don't
> like the changes or as Gintas has stating they make to code base
> cleaner.
>
> Honestly, I would prefer to not make this type of change at the scale
> they have happened. Mostly because I feel I'm spending a lot of time
> reviewing changes that transform working code into equivalent working
> code. Not reviewig the changes is not an option.
>
> Stefan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Stefan Bodewig
On 2018-04-11, Matt Benson wrote:

> On Sun, Apr 8, 2018, 11:03 AM Stefan Bodewig <[hidden email]> wrote:

>> We did have one big "cleanup" commit which has been the one that brought
>> us the regressions in 1.10.2 and I deeply regret not taking the time
>> reviewing the change back then.

> I'm pretty sure I was the perpetrator of said commit and wanted to offer my
> apologies.

I didn't mean to single you out. It is incredibly hard to review diffs
with several thousand lines (or multiple diffs with several hundred) and
this is not only true for the reviewer but also for the person who
created the change. It is way to easy to miss the dropped exclamation
mark or the stripped null guard in this situtation.

Personally I prefer cleanups in smaller doses by now, i.e. fix code when
I'm making changes close by anyway, and leave it alone otherwise.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Matt Benson-2
On Wed, Apr 11, 2018, 8:25 AM Stefan Bodewig <[hidden email]> wrote:

> On 2018-04-11, Matt Benson wrote:
>
> > On Sun, Apr 8, 2018, 11:03 AM Stefan Bodewig <[hidden email]> wrote:
>
> >> We did have one big "cleanup" commit which has been the one that brought
> >> us the regressions in 1.10.2 and I deeply regret not taking the time
> >> reviewing the change back then.
>
> > I'm pretty sure I was the perpetrator of said commit and wanted to offer
> my
> > apologies.
>
> I didn't mean to single you out.


I took no offense, only wanted to express regret for having been involved
in the project in such a limited capacity these past several years and then
dropping a couple of large commits without really helping to address the
fallout.

Matt

It is incredibly hard to review diffs

> with several thousand lines (or multiple diffs with several hundred) and
> this is not only true for the reviewer but also for the person who
> created the change. It is way to easy to miss the dropped exclamation
> mark or the stripped null guard in this situtation.
>
> Personally I prefer cleanups in smaller doses by now, i.e. fix code when
> I'm making changes close by anyway, and leave it alone otherwise.
>
> Stefan
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Gintautas Grigelionis
In reply to this post by Jaikiran Pai
2018-04-11 6:25 GMT+00:00 Jaikiran Pai <[hidden email]>:´

> On 10/04/18 12:27 AM, Gintautas Grigelionis wrote:
>
>> I wrote earlier that I was about to review the unit tests.
>> I was particularly unhappy about the root-property hack for an ancient
>> deficiency in Surefire.
>>
> I checked some of the mail discussions, but couldn't find any relevant
> details about this. Can you explain what the root-property hack is? I also
> don't understand how Surefire is related to our tests, which are run using
> the junit and ant-unit framework. If I missed some previous discussion,
> please pointme to it and I'll read up on that.


It's quite unobtrusive so far, see

https://github.com/apache/ant/commit/7a30a2b577ef60c6f05ccd9379326439f8c88fed
https://github.com/apache/ant/commit/4a8ef26e69a586684685ec1ca072fbbccc7c00b0

XMLCatalogTest is an example of unit tests complicated by root property.

Gintas
Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Gintautas Grigelionis
Hi Martin,

the issue is somewhat misleading. JUnit tests must be runner-agnostic, it
should make no difference whether it's Ant-JUnit* or Surefire.
However, it is my experience that Surefire needs basedir property to find
things where Ant-JUnit* finds them.
Once upon a time, Surefire lacked the possibility to set that property,
hence Ant's unit tests were complicated to work around that.
There is no need for any additional properties, but IMHO there is a need to
make tests simple and clean.
Else I must take care to set up the extra property in my IDE(s), and that I
would like to avoid.

Gintas

2018-04-12 12:05 GMT+00:00 Martin Gainty <[hidden email]>:

> Mornin' Gintas
>
> maven plugin maven-surefire-plugin 'basedir' property accurately refers to
> maven basedir
> (and not ant's basedir)
>
> external  tool properties/attributes should have a label indicating their
> external tool origin so
> ant basedir would be 'ant.basedir' property in maven-surefire-plugin
> if 'ant.basedir' is set maven-surefire-plugin would access testCases
> located under 'ant.basedir'
>
> it seems the timeline for this patch would be a quick update for
> maven-surefire-plugin (less than 1 day)
>
> can you propose the patch in maven-surefire-plugin JIRA
> https://issues.apache.org/jira/browse/SUREFIRE-184
> [SUREFIRE-184] [PATCH] make the basedir system property ...
> <https://issues.apache.org/jira/browse/SUREFIRE-184>
> issues.apache.org
> I wanted to run the ant testcases using the maven-surefire-plugin (I
> actually built all the ant jars using maven). The problem is that the
> plugin sets a system property basedir that ant cannot override.
>
> ?
>
> Martin
> ______________________________________________
>
>
>
>
> ------------------------------
> *From:* Gintautas Grigelionis <[hidden email]>
> *Sent:* Wednesday, April 11, 2018 4:44 PM
> *To:* Ant Developers List
> *Subject:* Re: Mass changes to various projects under Ant umbrella -
> should we be doing it?
>
> 2018-04-11 6:25 GMT+00:00 Jaikiran Pai <[hidden email]>:´
>
> > On 10/04/18 12:27 AM, Gintautas Grigelionis wrote:
> >
> >> I wrote earlier that I was about to review the unit tests.
> >> I was particularly unhappy about the root-property hack for an ancient
> >> deficiency in Surefire.
> >>
> > I checked some of the mail discussions, but couldn't find any relevant
> > details about this. Can you explain what the root-property hack is? I
> also
> > don't understand how Surefire is related to our tests, which are run
> using
> > the junit and ant-unit framework. If I missed some previous discussion,
> > please pointme to it and I'll read up on that.
>
>
> It's quite unobtrusive so far, see
>
> https://github.com/apache/ant/commit/7a30a2b577ef60c6f05ccd93793264
> 39f8c88fed
>
> <https://github.com/apache/ant/commit/7a30a2b577ef60c6f05ccd9379326439f8c88fed>
> update Maven documentation · apache/ant@7a30a2b
> <https://github.com/apache/ant/commit/7a30a2b577ef60c6f05ccd9379326439f8c88fed>
> github.com
> ant - Mirror of Apache Ant
>
>
> https://github.com/apache/ant/commit/4a8ef26e69a586684685ec1ca072fb
> bccc7c00b0
>
> XMLCatalogTest is an example of unit tests complicated by root property.
>
> Gintas
>
Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Stefan Bodewig
In reply to this post by Gintautas Grigelionis
On 2018-04-11, Gintautas Grigelionis wrote:

> 2018-04-11 6:25 GMT+00:00 Jaikiran Pai <[hidden email]>:´

>> On 10/04/18 12:27 AM, Gintautas Grigelionis wrote:

>>> I wrote earlier that I was about to review the unit tests.
>>> I was particularly unhappy about the root-property hack for an ancient
>>> deficiency in Surefire.

>> I checked some of the mail discussions, but couldn't find any relevant
>> details about this. Can you explain what the root-property hack is? I also
>> don't understand how Surefire is related to our tests, which are run using
>> the junit and ant-unit framework. If I missed some previous discussion,
>> please pointme to it and I'll read up on that.


> It's quite unobtrusive so far, see

> https://github.com/apache/ant/commit/7a30a2b577ef60c6f05ccd9379326439f8c88fed
> https://github.com/apache/ant/commit/4a8ef26e69a586684685ec1ca072fbbccc7c00b0

I don't think the root property is related to that at all. In fact it
predates the poms as far as I remember.

> XMLCatalogTest is an example of unit tests complicated by root property.

Actually, the test even passes if you remove the line using the property
as long as your current working directory is Ant's basedir :-)

https://github.com/apache/ant/commit/71333195c9d57d80d1a44cd8362a641c62d5e214

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Gintautas Grigelionis
2018-04-12 14:39 GMT+00:00 Stefan Bodewig <[hidden email]>:

> On 2018-04-11, Gintautas Grigelionis wrote:
>
> > XMLCatalogTest is an example of unit tests complicated by root property.
>
> Actually, the test even passes if you remove the line using the property
> as long as your current working directory is Ant's basedir :-)
>

What is the reason of having and/or keeping the property, anyway?

Gintas
Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Stefan Bodewig
On 2018-04-12, Gintautas Grigelionis wrote:

> 2018-04-12 14:39 GMT+00:00 Stefan Bodewig <[hidden email]>:

>> On 2018-04-11, Gintautas Grigelionis wrote:

>>> XMLCatalogTest is an example of unit tests complicated by root property.

>> Actually, the test even passes if you remove the line using the property
>> as long as your current working directory is Ant's basedir :-)

> What is the reason of having and/or keeping the property, anyway?

Running the test when your current working directory is not the root of
the Ant source tree. I don't know who does so, but it has been something
somebody needed some time ago (and took the time to make it
possible). Right now I don't see any reason to stop supporting that.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Gintautas Grigelionis
2018-04-12 15:18 GMT+00:00 Stefan Bodewig <[hidden email]>:

> On 2018-04-12, Gintautas Grigelionis wrote:
>
> > 2018-04-12 14:39 GMT+00:00 Stefan Bodewig <[hidden email]>:
>
> >> On 2018-04-11, Gintautas Grigelionis wrote:
>
> >>> XMLCatalogTest is an example of unit tests complicated by root
> property.
>
> >> Actually, the test even passes if you remove the line using the property
> >> as long as your current working directory is Ant's basedir :-)
>
> > What is the reason of having and/or keeping the property, anyway?
>
> Running the test when your current working directory is not the root of
> the Ant source tree. I don't know who does so, but it has been something
> somebody needed some time ago (and took the time to make it
> possible). Right now I don't see any reason to stop supporting that.
>

I'd say it's the other way around: unless I'm mistaken, I have to remember
to set the property in the IDEs that I use
if I want to use a test case for debugging. So IMHO it's an unnecessary
complication for no good reason.

Gintas
Reply | Threaded
Open this post in threaded view
|

Re: Mass changes to various projects under Ant umbrella - should we be doing it?

Stefan Bodewig
On 2018-04-12, Gintautas Grigelionis wrote:

> 2018-04-12 15:18 GMT+00:00 Stefan Bodewig <[hidden email]>:

>> On 2018-04-12, Gintautas Grigelionis wrote:

>>> 2018-04-12 14:39 GMT+00:00 Stefan Bodewig <[hidden email]>:

>>>> On 2018-04-11, Gintautas Grigelionis wrote:

>>>>> XMLCatalogTest is an example of unit tests complicated by root
>> property.

>>>> Actually, the test even passes if you remove the line using the property
>>>> as long as your current working directory is Ant's basedir :-)

>>> What is the reason of having and/or keeping the property, anyway?

>> Running the test when your current working directory is not the root of
>> the Ant source tree. I don't know who does so, but it has been something
>> somebody needed some time ago (and took the time to make it
>> possible). Right now I don't see any reason to stop supporting that.

> I'd say it's the other way around: unless I'm mistaken, I have to
> remember to set the property in the IDEs that I use if I want to use a
> test case for debugging. So IMHO it's an unnecessary complication for
> no good reason.

Ant test cases are not designed to be run from an IDE, this has never
been a goal. I'm surprised this system property is the only thing you
need to remember :-)

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

12