jdk/test/java/text/Format/common/dateFormat.props
author okutsu
Fri, 27 May 2016 14:33:48 +0900
changeset 38581 e761c1ccd13e
permissions -rw-r--r--
8031145: Re-examine closed i18n tests to see it they can be moved to the jdk repository. Reviewed-by: alanb, peytoia, naoto

#
# Copyright (c) 2000, 2016, 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
# under the terms of the GNU General Public License version 2 only, as
# published by the Free Software Foundation.
#
# This code is distributed in the hope that it will be useful, but WITHOUT
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
# version 2 for more details (a copy is included in the LICENSE file that
# accompanied this code).
#
# You should have received a copy of the GNU General Public License version
# 2 along with this work; if not, write to the Free Software Foundation,
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
#
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
# or visit www.oracle.com if you need additional information or have any
# questions.
#

# Test data for FormatIteratorTest

{
  tests =
  (
    {
      class = java.text.SimpleDateFormat
      args = ("M/dd/yy")
      valueClass = java.util.Date
      valueArgs = ("7/10/71")
    }
    {
      length = 7
      text = "7/10/71"
      0 = (DateFormat$Field.MONTH)
      1 = ()
      2 = (DateFormat$Field.DAY_OF_MONTH)
      3 = (DateFormat$Field.DAY_OF_MONTH)
      4 = ()
      5 = (DateFormat$Field.YEAR)
      6 = (DateFormat$Field.YEAR)
      limits = ( { attributes = (DateFormat$Field.MONTH)
                   begin = 0 end = 1}
                 { attributes = ()
                   begin = 1 begin2 = 0 end = 2 end2 = 7}
                 { attributes = (DateFormat$Field.DAY_OF_MONTH)
                   begin = 2 end = 4}
                 { attributes = ()
                   begin = 4 begin2 = 0 end = 5 end2 = 7}
                 { attributes = (DateFormat$Field.YEAR)
                   begin = 5 end = 7}
               )
      fieldPositions =
      (
        {
          field = DateFormat.MONTH_FIELD
          fieldID = DateFormat$Field.MONTH
          begin = 0 end = 1
        }
        {
          field = DateFormat.DATE_FIELD
          fieldID = DateFormat$Field.DAY_OF_MONTH
          begin = 2 end = 4
        }
        {
          field = DateFormat.YEAR_FIELD
          fieldID = DateFormat$Field.YEAR
          begin = 5 end = 7
        }
      )
    }

    {
      class = java.text.SimpleDateFormat
      args = ("EEEEEEE MMMMMMMMMMMMM yyyy GG")
      valueClass = java.util.Date
      valueArgs = ("12/10/2020")
    }
    {
      length = 25
      text = "Thursday December 2020 AD"
      0 = (DateFormat$Field.DAY_OF_WEEK)
      1 = (DateFormat$Field.DAY_OF_WEEK)
      2 = (DateFormat$Field.DAY_OF_WEEK)
      3 = (DateFormat$Field.DAY_OF_WEEK)
      4 = (DateFormat$Field.DAY_OF_WEEK)
      5 = (DateFormat$Field.DAY_OF_WEEK)
      6 = (DateFormat$Field.DAY_OF_WEEK)
      7 = (DateFormat$Field.DAY_OF_WEEK)
      8 = ()
      9 = (DateFormat$Field.MONTH)
      10 = (DateFormat$Field.MONTH)
      11 = (DateFormat$Field.MONTH)
      12 = (DateFormat$Field.MONTH)
      13 = (DateFormat$Field.MONTH)
      14 = (DateFormat$Field.MONTH)
      15 = (DateFormat$Field.MONTH)
      16 = (DateFormat$Field.MONTH)
      17 = ()
      18 = (DateFormat$Field.YEAR)
      19 = (DateFormat$Field.YEAR)
      20 = (DateFormat$Field.YEAR)
      21 = (DateFormat$Field.YEAR)
      22 = ()
      23 = (DateFormat$Field.ERA)
      24 = (DateFormat$Field.ERA)
      limits = ( { attributes = (DateFormat$Field.DAY_OF_WEEK)
                   begin = 0 end = 8}
                 { attributes = ()
                   begin = 8 begin2 = 0 end = 9 end2 = 25}
                 { attributes = (DateFormat$Field.MONTH)
                   begin = 9 end = 17}
                 { attributes = ()
                   begin = 17 begin2 = 0 end = 18 end2 = 25}
                 { attributes = (DateFormat$Field.YEAR)
                   begin = 18 end = 22}
                 { attributes = ()
                   begin = 22 begin2 = 0 end = 23 end2 = 25}
                 { attributes = (DateFormat$Field.ERA)
                   begin = 23 end = 25}
               )
      fieldPositions =
      (
        {
          field = DateFormat.DAY_OF_WEEK_FIELD
          fieldID = DateFormat$Field.DAY_OF_WEEK
          begin = 0 end = 8
        }
        {
          field = DateFormat.MONTH_FIELD
          fieldID = DateFormat$Field.MONTH
          begin = 9 end = 17
        }
        {
          field = DateFormat.YEAR_FIELD
          fieldID = DateFormat$Field.YEAR
          begin = 18 end = 22
        }
        {
          field = DateFormat.ERA_FIELD
          fieldID = DateFormat$Field.ERA
          begin = 23 end = 25
        }
      )
    }

    {
      class = java.text.SimpleDateFormat
      args = ("h HH:mm:ss:SSS aa")
      valueClass = java.util.Date
      valueArgs = ("1/1/2000 2:52:12 PM")
    }
    {
      length = 17
      text = "2 14:52:12:000 PM"
      0 = (DateFormat$Field.HOUR1)
      1 = ()
      2 = (DateFormat$Field.HOUR_OF_DAY0)
      3 = (DateFormat$Field.HOUR_OF_DAY0)
      4 = ()
      5 = (DateFormat$Field.MINUTE)
      6 = (DateFormat$Field.MINUTE)
      7 = ()
      8 = (DateFormat$Field.SECOND)
      9 = (DateFormat$Field.SECOND)
      10 = ()
      11 = (DateFormat$Field.MILLISECOND)
      12 = (DateFormat$Field.MILLISECOND)
      13 = (DateFormat$Field.MILLISECOND)
      14 = ()
      15 = (DateFormat$Field.AM_PM)
      16 = (DateFormat$Field.AM_PM)
      limits = ( { attributes = (DateFormat$Field.HOUR1)
                   begin = 0 end = 1}
                 { attributes = ()
                   begin = 1 begin2 = 0 end = 2 end2 = 17}
                 { attributes = (DateFormat$Field.HOUR_OF_DAY0)
                   begin = 2 end = 4}
                 { attributes = ()
                   begin = 4 begin2 = 0 end = 5 end2 = 17}
                 { attributes = (DateFormat$Field.MINUTE)
                   begin = 5 end = 7}
                 { attributes = ()
                   begin = 7 begin2 = 0 end = 8 end2 = 17}
                 { attributes = (DateFormat$Field.SECOND)
                   begin = 8 end = 10}
                 { attributes = ()
                   begin = 10 begin2 = 0 end = 11 end2 = 17}
                 { attributes = (DateFormat$Field.MILLISECOND)
                   begin = 11 end = 14}
                 { attributes = ()
                   begin = 14 begin2 = 0 end = 15 end2 = 17}
                 { attributes = (DateFormat$Field.AM_PM)
                   begin = 15 end = 17}
               )
      fieldPositions =
      (
        {
          field = DateFormat.HOUR1_FIELD
          fieldID = DateFormat$Field.HOUR1
          begin = 0 end = 1
        }
        {
          field = DateFormat.HOUR_OF_DAY0_FIELD
          fieldID = DateFormat$Field.HOUR_OF_DAY0
          begin = 2 end = 4
        }
        {
          field = DateFormat.MINUTE_FIELD
          fieldID = DateFormat$Field.MINUTE
          begin = 5 end = 7
        }
        {
          field = DateFormat.SECOND_FIELD
          fieldID = DateFormat$Field.SECOND
          begin = 8 end = 10
        }
        {
          field = DateFormat.MILLISECOND_FIELD
          fieldID = DateFormat$Field.MILLISECOND
          begin = 11 end = 14
        }
        {
          field = DateFormat.AM_PM_FIELD
          fieldID = DateFormat$Field.AM_PM
          begin = 15 end = 17
        }
      )
    }


    {
      class = java.text.SimpleDateFormat
      args = ("kk KK DDD FF ww WW zz")
      valueClass = java.util.Date
      valueArgs = ("4/26/2031 2:02:52 AM")
    }
    {
      length = 22
      text = "02 02 116 04 17 04 PDT"
      0 = (DateFormat$Field.HOUR_OF_DAY1)
      1 = (DateFormat$Field.HOUR_OF_DAY1)
      2 = ()
      3 = (DateFormat$Field.HOUR0)
      4 = (DateFormat$Field.HOUR0)
      5 = ()
      6 = (DateFormat$Field.DAY_OF_YEAR)
      7 = (DateFormat$Field.DAY_OF_YEAR)
      8 = (DateFormat$Field.DAY_OF_YEAR)
      9 = ()
      10 = (DateFormat$Field.DAY_OF_WEEK_IN_MONTH)
      11 = (DateFormat$Field.DAY_OF_WEEK_IN_MONTH)
      12 = ()
      13 = (DateFormat$Field.WEEK_OF_YEAR)
      14 = (DateFormat$Field.WEEK_OF_YEAR)
      15 = ()
      16 = (DateFormat$Field.WEEK_OF_MONTH)
      17 = (DateFormat$Field.WEEK_OF_MONTH)
      18 = ()
      19 = (DateFormat$Field.TIME_ZONE)
      20 = (DateFormat$Field.TIME_ZONE)
      21 = (DateFormat$Field.TIME_ZONE)
      limits = ( { attributes = (DateFormat$Field.HOUR_OF_DAY1)
                   begin = 0 end = 2}
                 { attributes = ()
                   begin = 2 begin2 = 0 end = 3 end2 = 22}
                 { attributes = (DateFormat$Field.HOUR0)
                   begin = 3 end = 5}
                 { attributes = ()
                   begin = 5 begin2 = 0 end = 6 end2 = 22}
                 { attributes = (DateFormat$Field.DAY_OF_YEAR)
                   begin = 6 end = 9}
                 { attributes = ()
                   begin = 9 begin2 = 0 end = 10 end2 = 22}
                 { attributes = (DateFormat$Field.DAY_OF_WEEK_IN_MONTH)
                   begin = 10 end = 12}
                 { attributes = ()
                   begin = 12 begin2 = 0 end = 13 end2 = 22}
                 { attributes = (DateFormat$Field.WEEK_OF_YEAR)
                   begin = 13 end = 15}
                 { attributes = ()
                   begin = 15 begin2 = 0 end = 16 end2 = 22}
                 { attributes = (DateFormat$Field.WEEK_OF_MONTH)
                   begin = 16 end = 18}
                 { attributes = ()
                   begin = 18 begin2 = 0 end = 19 end2 = 22}
                 { attributes = (DateFormat$Field.TIME_ZONE)
                   begin = 19 end = 22}
               )
      fieldPositions =
      (
        {
          field = DateFormat.HOUR_OF_DAY1_FIELD
          fieldID = DateFormat$Field.HOUR_OF_DAY1
          begin = 0 end = 2
        }
        {
          field = DateFormat.HOUR0_FIELD
          fieldID = DateFormat$Field.HOUR0
          begin = 3 end = 5
        }
        {
          field = DateFormat.DAY_OF_YEAR_FIELD
          fieldID = DateFormat$Field.DAY_OF_YEAR
          begin = 6 end = 9
        }
        {
          field = DateFormat.DAY_OF_WEEK_IN_MONTH_FIELD
          fieldID = DateFormat$Field.DAY_OF_WEEK_IN_MONTH
          begin = 10 end = 12
        }
        {
          field = DateFormat.WEEK_OF_YEAR_FIELD
          fieldID = DateFormat$Field.WEEK_OF_YEAR
          begin = 13 end = 15
        }
        {
          field = DateFormat.WEEK_OF_MONTH_FIELD
          fieldID = DateFormat$Field.WEEK_OF_MONTH
          begin = 16 end = 18
        }
        {
          field = DateFormat.TIMEZONE_FIELD
          fieldID = DateFormat$Field.TIME_ZONE
          begin = 19 end = 22
        }
      )
    }
  )
}