On Tue, 17 May 2022 08:57:54 GMT, Hannes Wallnöfer <hann...@openjdk.org> wrote:

>> test/langtools/jdk/javadoc/lib/javadoc/tester/JavadocTester.java line 1089:
>> 
>>> 1087:                 content = null;
>>> 1088:             } else {
>>> 1089:                 name = outputDir + "/" + file;
>> 
>> I'm trying to understand the merit of this, since the output directory is 
>> often just `out` or `api` isn't it? Don't you want the test method name in 
>> there, for increased resolution?
>
> For test classes containing multiple test methods the output directory is 
> actually the best way to identify which run of javadoc generated the output. 
> If a test were to do multiple runs of javadoc with the same output directory 
> I would certainly consider it a serious bug. Also, a single test method could 
> easily do multiple runs of javadoc (I'm not sure we do that in our test 
> suite, but I wouldn't be too surprised).  Adding the output directory 
> disambiguates the file name which is already there, making it easy to locate 
> the file itself and the code that generated it.

OK; just verify it doesn't break existing tests!

-------------

PR: https://git.openjdk.java.net/jdk/pull/8657

Reply via email to