8222444: Add a suggestion for non-US locale in the test doc jdk-13+17
authorerikj
Wed, 17 Apr 2019 13:18:29 -0700
changeset 54570 93b702d2a0cb
parent 54569 7689e1cc56fe
child 54571 5de35f58f70c
8222444: Add a suggestion for non-US locale in the test doc Reviewed-by: erikj Contributed-by: jingtian@loongson.cn
doc/testing.html
doc/testing.md
--- a/doc/testing.html	Wed Apr 17 08:12:19 2019 -0700
+++ b/doc/testing.html	Wed Apr 17 13:18:29 2019 -0700
@@ -41,6 +41,7 @@
 </ul></li>
 <li><a href="#notes-for-specific-tests">Notes for Specific Tests</a><ul>
 <li><a href="#docker-tests">Docker Tests</a></li>
+<li><a href="#non-us-locale">Non-US locale</a></li>
 </ul></li>
 </ul>
 </nav>
@@ -194,5 +195,9 @@
 <pre><code>$ make test TEST=&quot;jtreg:test/hotspot/jtreg/containers/docker&quot;</code></pre>
 <p>To run these tests correctly, additional parameters for the correct docker image are required on Ubuntu 18.04 by using <code>JAVA_OPTIONS</code>.</p>
 <pre><code>$ make test TEST=&quot;jtreg:test/hotspot/jtreg/containers/docker&quot; JTREG=&quot;JAVA_OPTIONS=-Djdk.test.docker.image.name=ubuntu -Djdk.test.docker.image.version=latest&quot;</code></pre>
+<h3 id="non-us-locale">Non-US locale</h3>
+<p>If your locale is non-US, some tests are likely to fail. To work around this you can set the locale to US. On Unix platforms simply setting <code>LANG=&quot;en_US&quot;</code> in the environment before running tests should work. On Windows, setting <code>JTREG=&quot;VM_OPTIONS=-Duser.language=en -Duser.country=US&quot;</code> helps for most, but not all test cases. For example:</p>
+<pre><code>$ export LANG=&quot;en_US&quot; &amp;&amp; make test TEST=...
+$ make test JTREG=&quot;VM_OPTIONS=-Duser.language=en -Duser.country=US&quot; TEST=...</code></pre>
 </body>
 </html>
--- a/doc/testing.md	Wed Apr 17 08:12:19 2019 -0700
+++ b/doc/testing.md	Wed Apr 17 13:18:29 2019 -0700
@@ -388,6 +388,17 @@
 
     $ make test TEST="jtreg:test/hotspot/jtreg/containers/docker" JTREG="JAVA_OPTIONS=-Djdk.test.docker.image.name=ubuntu -Djdk.test.docker.image.version=latest"
 
+### Non-US locale
+
+If your locale is non-US, some tests are likely to fail. To work around this you can
+set the locale to US. On Unix platforms simply setting `LANG="en_US"` in the
+environment before running tests should work. On Windows, setting
+`JTREG="VM_OPTIONS=-Duser.language=en -Duser.country=US"` helps for most, but not all test cases.
+For example:
+
+    $ export LANG="en_US" && make test TEST=...
+    $ make test JTREG="VM_OPTIONS=-Duser.language=en -Duser.country=US" TEST=...
+
 ---
 # Override some definitions in the global css file that are not optimal for
 # this document.