RFR: 8290149: java/nio/file/Files/probeContentType/Basic.java fails on Windows Server 2019/2022

Brian Burkhalter brian.burkhalter at oracle.com
Wed Jul 13 15:15:59 UTC 2022


On Jul 13, 2022, at 7:13 AM, Maxim Kartashev <mkartashev at openjdk.org<mailto:mkartashev at openjdk.org>> wrote:

On Tue, 12 Jul 2022 06:41:35 GMT, KIRIYAMA Takuya <duke at openjdk.org<mailto:duke at openjdk.org>> wrote:

On Windows Server 2019/2022, default content type of ".js" is set to "text/plain" in registry.


C:\>reg query HKEY_CLASSES_ROOT.js /v "Content Type"

HKEY_CLASSES_ROOT.js
   Content Type    REG_SZ    text/plain


So, "text/plain" should be added for content type of ".js".

I propose to add default registry value to expected list. After fix, test passes on Windows Server 2022.

Could you review this fix, please?

The test failed in exactly this fashion on my Windows 10 system; happy to see this resolved.

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

PR: https://git.openjdk.org/jdk/pull/9459

Two of us run the same version of macOS and one person saw the failure but the other did not. On the failing machine WinZip was installed and there was speculation that that might be the reason, i.e., it installs an additional MIME type.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/nio-dev/attachments/20220713/80c1c187/attachment-0001.htm>


More information about the nio-dev mailing list