|
Home About Us A-Z Index Search * Contact Us Register Login Press ShopThe Open Brand -- Problem Reporting and Interpretations System |
Problem Report 0157 Details
Show help | Quick Search | Submit a Test Suite Support Request | Click here to view your privileges
This page provides all information on Problem Report 0157.
Report 0157 Actions
Problem Report Number 0157 Submitter's Classification Test Suite problem State Resolved Resolution Test Suite Deficiency (TSD) Problem Resolution ID TSD.X.0157 Raised 1994-06-09 08:00 Updated 2003-03-13 08:00 Published 1994-06-14 08:00 Product Standard Internationalised System Calls and Libraries (XPG4) Certification Program The Open Brand certification program Test Suite VSX4 version 4.3.2 Test Identification XPG4.os/time/strptime 3,5 Linked Problem Reports TSD4.078, TSD4.079, (in, old, system) Problem Summary TSD4.157 In the above test cases a fix was made in VSX 4.3.2 which changed the ASCII spaces to VSX4L1 spaces (0100). However, the change was only made to the strings being formatted and not to the actual forma... Problem Text
In the above test cases a fix was made in VSX 4.3.2 which changed the ASCII
spaces to VSX4L1 spaces (0100). However, the change was only made to the
strings being formatted and not to the actual format string. Since the
two ASCII spaces in the format string are considered ordinary characters
in the VSX4L1 locale, not white-space ones, because isspace(' ') is false in
the VSX4L1 locale. The XPG4 strptime() page says that white-space
characters are "as specified by the isspace() function". It seems that
the ASCII space characters should have been changed to VSX4L1 space
characters in the format string, as well.Test Output
************************************************************************
/tset/XPG4.os/time/strptime/T.strptime 3 Failed
Test Description:
If strptime() is supported:
When format is a string made up of a series of the following field
descriptors :
a. d day of month - 01 to 31 (with or without leading zeros)
b. D date in %m/%d/%y format
c. H hour - 00 to 23 (with or without leading zeros)
d. I hour - 00 to 12 (with or without leading zeros)
e. j day of year - 001 to 366
f. M minute - 00 to 59 (with or without leading zeros)
g. m month of year - 01 to 12 (with or without leading zeros)
h. n any whitespace character sequence
i. r time in %I:%M:%S %p format
j. S second - 00 to 61 (with or without leading zeros)
k. t any whitespace character sequence
l. T time in %H:%M:%S notation
m. U week number of year - 00 to 53 (Sunday as first day of week)
(with or without leading zeros)
n. w day of week - 0 to 6 (Sunday = 0) (with or without leading
zeros)
o. W week number of year - 00 to 53 (Monday as first day of week)
(with or without leading zeros)
p. y last two digits of year - 00 to 99 (with or without leading
zeros)
q. Y four digit year including century
then a call to strptime() reads characters from string and, in the
case that these characters match the format of the directive,
translates these characters into the appropriate member of the tm
structure. Occurrences of "%%" in the format string are matched
against a single "%" and do not affect the tm structure.
Otherwise:
A call to strptime() returns NULL and sets errno to ENOSYS.
Test Strategy:
PARENT process will
CREATE child process using cppair()
CHILD process will
FOR each item in the assertion, and for fields with and without
leading zeroes where allowed, and for locales VSX4L1 and VSX4L2
where indicated:
INITIALISE the tm structure to be set by strptime()
INITIALISE the tm structure that strptime() will be checked
against.
IF testing the %p format:
SET the locale for LC_TIME to VSX4L1 or VSX4L2
OBTAIN the relevant pseudo-language data using pslanginfo()
CONVERT the date and time string to a tm structure using
strptime()
VERIFY strptime() returns the expected tm structure.
Test Information:
time in %I:%M:%S %p format
strptime("11'40'15 NM", "%r", &testbuf) failed.
Current language is VSX4L1
return value was NULL
time in %I:%M:%S %p format
strptime("11'49'45 am", "%r", &testbuf) failed.
Current language is VSX4L2
return value was NULL
weekday , two digit year, and week number of the year, with leading
zeroes
strptime("0091@00@01", "%y %w %U", &testbuf) failed.
return value was NULL
weekday , two digit year, and week number of the year, without leading
zeroes
strptime("92@4@52", "%y %w %U", &testbuf) failed.
return value was NULL
weekday , two digit year, and week number of the year, with leading
zeroes
strptime("0091@00@01", "%y %w %W", &testbuf) failed.
return value was NULL
weekday , two digit year, and week number of the year, without leading
zeroes
strptime("92@4@52", "%y %w %W", &testbuf) failed.
return value was NULL
%% in format string is mapped to % in test string
strptime("%@1991@%", "%% %Y %%", &testbuf) failed.
return value was NULL
************************************************************************
/tset/XPG4.os/time/strptime/T.strptime 5 Failed
Test Description:
If strptime() is supported:
When format is a string containing the following field descriptors
:
a. a or A abbreviated or full weekday name - eg. Sun to Sat or
Sunday to Saturday
b. b, B or h abbreviated or full month name - eg. Jan to Dec or
January to December
c. c appropriate date and time as specified in the D_T_FMT string
d. p AM/PM string as specified in the AM_STR/PM_STR
e. x appropriate date as specified in the D_FMT string
f. X appropriate time as specified in the T_FMT string
then a call to strptime() reads characters from string and, in the
case that these characters match the format of the directive,
translates these characters into the appropriate member of the tm
structure.
Otherwise:
A call to strptime() returns NULL and sets errno to ENOSYS.
Test Strategy:
PARENT process will
CREATE child process using cppair()
CHILD process will
SET the locale for LC_TIME to VSX4L1
FOR each day format
FOR each full weekday name
GET the relevant string using pslanginfo()
INITIALISE the tm structures
VERIFY that strptime() performs as expected
FOR each abbreviated weekday name
GET the relevant string using pslanginfo()
INITIALISE the tm structures
VERIFY that strptime() performs as expected
FOR each month format
FOR each full month name
GET the relevant string using pslanginfo()
INITIALISE the tm structures
VERIFY that strptime() performs as expected
FOR each abbreviated month name
GET the relevant string using pslanginfo()
INITIALISE the tm structures
VERIFY that strptime() performs as expected
FOR format strings D_T_FMT, AM_STR, D_FMT, and T_FMT:
INITIALISE the tm structures
VERIFY that strptime() performs as expected
REPEAT everything contained above in this test for the locale
VSX4L2
Test Information:
appropriate date and time as specified in D_T_FMT string
strptime("6\05642\05621 NM 09\05705\05791", "%c", &testbuf) failed.
Current language is VSX4L1
return value was NULL
AM string as specified in AM_STR
strptime("6 VM", "%I %p", &testbuf) failed.
Current language is VSX4L1
return value was NULL
appropriate time as specified in T_FMT string
strptime("6\05642\05621 NM", "%X", &testbuf) failed.
Current language is VSX4L1
return value was NULL
appropriate date and time as specified in D_T_FMT string
strptime("5 9 1991 6'42'21", "%c", &testbuf) failed.
Current language is VSX4L2
return value was NULL
PM string as specified in PM_STR
strptime("6 pm", "%I %p", &testbuf) failed.
Current language is VSX4L2
return value was NULL
appropriate date as specified in D_FMT string
strptime("05 09 1991", "%x", &testbuf) failed.
Current language is VSX4L2
return value was NULL
************************************************************************Review Information
Review Type TSMA Review Start Date null Completed null Status Complete Review Recommendation No Resolution Given Review Response
This is an accepted test suite fault and it is recommended that a waiver
be granted for this test suite deficiency.
Review Type SA Review Start Date null Completed null Status Complete Review Resolution Test Suite Deficiency (TSD) Review Conclusion
This is an agreed test suite deficiency.
Problem Reporting System Options:
- View Report 0157
- List All PRs
- Search Reports
- Email the System Administrator
- View the The Open Brand Interpretations Database User Manual
Contact the Certification Authority