--- old/test/jdk/java/text/Format/DateFormat/DateFormatTest.java 2019-01-17 08:32:15.153897446 -0800 +++ new/test/jdk/java/text/Format/DateFormat/DateFormatTest.java 2019-01-17 08:32:13.937872016 -0800 @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2016, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2019, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -24,6 +24,7 @@ /** * @test * @bug 4052223 4089987 4469904 4326988 4486735 8008577 8045998 8140571 + * 8216969 * @summary test DateFormat and SimpleDateFormat. * @library /java/text/testlib * @modules jdk.localedata @@ -1205,4 +1206,18 @@ TimeZone.setDefault(initialTimeZone); } } + + public void Test8216969() throws Exception { + Locale locale = new Locale("ru"); + String format = "\u0434\u0435\u043a"; + String standalone = "\u0434\u0435\u043a."; + + // Check that format form is used so that the dot is parsed correctly. + SimpleDateFormat simpleDateFormat = new SimpleDateFormat("dd MMM.yyyy", locale); + System.out.println(simpleDateFormat.parse("28 " + format + ".2018")); + + // Check that standalone form is used. + simpleDateFormat = new SimpleDateFormat("MMM", locale); + System.out.println(simpleDateFormat.parse(standalone)); + } }