RFR: 8273507: Convert test/jdk/java/nio/channels/Channels/TransferTo.java to TestNG test [v2]
Markus KARG
github.com+1701815+mkarg at openjdk.java.net
Wed Sep 15 06:01:47 UTC 2021
On Mon, 13 Sep 2021 09:10:13 GMT, Alan Bateman <alanb at openjdk.org> wrote:
> Ugh, please no. As Lance said, we need the source and tests to be as easy to maintain as possible. In this case it would be helpful to have comments on testStreamContents and checkTransferredContents so that it's very quick for someone to know what the test is trying to when it fails (in this area, most of the effort on tests is spent chasing intermittent test failures).
But that is **exactly** what BDD is good for, so I do not understand why you say "Ugh, please no."?!
As Aleksey wrote he had no problems understanding the tests, so frankly spoken, I don't know **what** to write in the comments as it all looks pretty self-explanatory to me. I'm fine with adding your prefered wordings if you just type them into the comments. Unfortunately I cannot take [Brian's code](https://github.com/bplb/jdk/blob/3e575ba2f8d631e48cc50ca44898844790dd1ea7/test/jdk/java/io/FileInputStream/TransferTo.java) as a blue print here, as nobody asked for tests *there* so it simply says `test` which is more or less non-explanatory at all (and, BTW, I do not understand why *his* test shall be any simpler to maintain than mine to get a clue **what** you want me to actually document).
-------------
PR: https://git.openjdk.java.net/jdk/pull/5421
More information about the nio-dev
mailing list