1570af302Sopenharmony_ci/** 2570af302Sopenharmony_ci * Copyright (c) 2022 Huawei Device Co., Ltd. 3570af302Sopenharmony_ci * Licensed under the Apache License, Version 2.0 (the "License"); 4570af302Sopenharmony_ci * you may not use this file except in compliance with the License. 5570af302Sopenharmony_ci * You may obtain a copy of the License at 6570af302Sopenharmony_ci * 7570af302Sopenharmony_ci * http://www.apache.org/licenses/LICENSE-2.0 8570af302Sopenharmony_ci * 9570af302Sopenharmony_ci * Unless required by applicable law or agreed to in writing, software 10570af302Sopenharmony_ci * distributed under the License is distributed on an "AS IS" BASIS, 11570af302Sopenharmony_ci * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12570af302Sopenharmony_ci * See the License for the specific language governing permissions and 13570af302Sopenharmony_ci * limitations under the License. 14570af302Sopenharmony_ci */ 15570af302Sopenharmony_ci 16570af302Sopenharmony_ci#include <stdlib.h> 17570af302Sopenharmony_ci#include <time.h> 18570af302Sopenharmony_ci#include "asctime_data.h" 19570af302Sopenharmony_ci#include "functionalext.h" 20570af302Sopenharmony_ci#include "strptime_data.h" 21570af302Sopenharmony_ci 22570af302Sopenharmony_cistatic int16_t gBufferSize = 256; 23570af302Sopenharmony_cistatic time_t gTime = 1659177614; 24570af302Sopenharmony_cistatic int16_t gYearBase = 1900; 25570af302Sopenharmony_ci 26570af302Sopenharmony_ci/** 27570af302Sopenharmony_ci * @tc.name : strptime_0100 28570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 29570af302Sopenharmony_ci * type according to a specific time format 30570af302Sopenharmony_ci * @tc.level : Level 0 31570af302Sopenharmony_ci */ 32570af302Sopenharmony_civoid strptime_0100(void) 33570af302Sopenharmony_ci{ 34570af302Sopenharmony_ci for ( int32_t i = 0; i < (int32_t)(sizeof(test_asctime_data) / sizeof(test_asctime_data[0])); i++) { 35570af302Sopenharmony_ci const char *handlerChar = test_handle_path(test_asctime_data[i].tz); 36570af302Sopenharmony_ci if (!handlerChar) { 37570af302Sopenharmony_ci t_error("strptime_0100 failed: handlerChar is NULL\n"); 38570af302Sopenharmony_ci continue; 39570af302Sopenharmony_ci } 40570af302Sopenharmony_ci 41570af302Sopenharmony_ci setenv("TZ", handlerChar, 1); 42570af302Sopenharmony_ci tzset(); 43570af302Sopenharmony_ci char buffer[gBufferSize]; 44570af302Sopenharmony_ci struct tm *timeptr = localtime(&gTime); 45570af302Sopenharmony_ci if (!timeptr) { 46570af302Sopenharmony_ci EXPECT_PTRNE("strptime_0100", timeptr, NULL); 47570af302Sopenharmony_ci return; 48570af302Sopenharmony_ci } 49570af302Sopenharmony_ci size_t cnt = strftime(buffer, sizeof(buffer) - 1, "%c", timeptr); 50570af302Sopenharmony_ci EXPECT_TRUE("strptime_0100", cnt > 0); 51570af302Sopenharmony_ci 52570af302Sopenharmony_ci struct tm tmTime = {0}; 53570af302Sopenharmony_ci strptime(buffer, "%c", &tmTime); 54570af302Sopenharmony_ci char *result = asctime(&tmTime); 55570af302Sopenharmony_ci if (result == NULL) { 56570af302Sopenharmony_ci EXPECT_FALSE("strptime_0100", result == NULL); 57570af302Sopenharmony_ci return; 58570af302Sopenharmony_ci } 59570af302Sopenharmony_ci result[strlen(result) - 1] = 0x00; 60570af302Sopenharmony_ci EXPECT_STREQ("strptime_0100", test_asctime_data[i].result, result); 61570af302Sopenharmony_ci } 62570af302Sopenharmony_ci} 63570af302Sopenharmony_ci 64570af302Sopenharmony_ci/** 65570af302Sopenharmony_ci * @tc.name : strptime_0200 66570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 67570af302Sopenharmony_ci * type according to a specific time format 68570af302Sopenharmony_ci * @tc.level : Level 0 69570af302Sopenharmony_ci */ 70570af302Sopenharmony_civoid strptime_0200(void) 71570af302Sopenharmony_ci{ 72570af302Sopenharmony_ci for ( int32_t i = 0; i < (int32_t)(sizeof(test_strptime_data)/sizeof(test_strptime_data[0])); i++) { 73570af302Sopenharmony_ci const char *handlerChar = test_handle_path(test_strptime_data[i].tz); 74570af302Sopenharmony_ci if (!handlerChar) { 75570af302Sopenharmony_ci t_error("strptime_0200 failed: handlerChar is NULL\n"); 76570af302Sopenharmony_ci continue; 77570af302Sopenharmony_ci } 78570af302Sopenharmony_ci 79570af302Sopenharmony_ci setenv("TZ", handlerChar, 1); 80570af302Sopenharmony_ci tzset(); 81570af302Sopenharmony_ci char buffer[gBufferSize]; 82570af302Sopenharmony_ci struct tm *timeptr = localtime(&gTime); 83570af302Sopenharmony_ci if (!timeptr) { 84570af302Sopenharmony_ci EXPECT_TRUE("strptime_0200", timeptr == NULL); 85570af302Sopenharmony_ci return; 86570af302Sopenharmony_ci } 87570af302Sopenharmony_ci size_t len = strftime(buffer, sizeof(buffer) - 1, "%c %Z%z", timeptr); 88570af302Sopenharmony_ci EXPECT_TRUE("strptime_0200", len > 0); 89570af302Sopenharmony_ci struct tm tmTime = {0}; 90570af302Sopenharmony_ci strptime(buffer, "%c %Z%z", &tmTime); 91570af302Sopenharmony_ci char buffResult[gBufferSize]; 92570af302Sopenharmony_ci 93570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d-%d-%d %d:%d:%d wday=%d,yday=%d,isdst=%d,gmtoff=%ld,zone=%s", 94570af302Sopenharmony_ci (tmTime.tm_year+gYearBase), tmTime.tm_mon, tmTime.tm_mday, tmTime.tm_hour, 95570af302Sopenharmony_ci tmTime.tm_min, tmTime.tm_sec, tmTime.tm_wday, tmTime.tm_yday, tmTime.tm_isdst, 96570af302Sopenharmony_ci tmTime.tm_gmtoff, tmTime.tm_zone); 97570af302Sopenharmony_ci EXPECT_TRUE("strptime_0200", cnt > 0); 98570af302Sopenharmony_ci EXPECT_STREQ("strptime_0200", test_strptime_data[i].result, buffResult); 99570af302Sopenharmony_ci } 100570af302Sopenharmony_ci} 101570af302Sopenharmony_ci 102570af302Sopenharmony_ci/** 103570af302Sopenharmony_ci * @tc.name : strptime_0300 104570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 105570af302Sopenharmony_ci * type according to a specific time format 106570af302Sopenharmony_ci * @tc.level : Level 0 107570af302Sopenharmony_ci */ 108570af302Sopenharmony_civoid strptime_0300(void) 109570af302Sopenharmony_ci{ 110570af302Sopenharmony_ci char *buffer = "2022-04-10"; 111570af302Sopenharmony_ci struct tm tmTime = {0}; 112570af302Sopenharmony_ci strptime(buffer, "%F", &tmTime); 113570af302Sopenharmony_ci char buffResult[gBufferSize]; 114570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%04d-%02d-%02d", 115570af302Sopenharmony_ci (tmTime.tm_year+gYearBase), tmTime.tm_mon + 1, tmTime.tm_mday); 116570af302Sopenharmony_ci EXPECT_TRUE("strptime_0300", cnt > 0); 117570af302Sopenharmony_ci EXPECT_STREQ("strptime_0300", buffer, buffResult); 118570af302Sopenharmony_ci} 119570af302Sopenharmony_ci 120570af302Sopenharmony_ci/** 121570af302Sopenharmony_ci * @tc.name : strptime_0400 122570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 123570af302Sopenharmony_ci * type according to a specific time format 124570af302Sopenharmony_ci * @tc.level : Level 0 125570af302Sopenharmony_ci */ 126570af302Sopenharmony_civoid strptime_0400(void) 127570af302Sopenharmony_ci{ 128570af302Sopenharmony_ci char *buffer = "23"; 129570af302Sopenharmony_ci struct tm tmTime = {0}; 130570af302Sopenharmony_ci strptime(buffer, "%g", &tmTime); 131570af302Sopenharmony_ci char buffResult[gBufferSize]; 132570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d", tmTime.tm_year); 133570af302Sopenharmony_ci EXPECT_TRUE("strptime_0400", cnt > 0); 134570af302Sopenharmony_ci EXPECT_STREQ("strptime_0400", buffer, buffResult); 135570af302Sopenharmony_ci} 136570af302Sopenharmony_ci 137570af302Sopenharmony_ci/** 138570af302Sopenharmony_ci * @tc.name : strptime_0500 139570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 140570af302Sopenharmony_ci * type according to a specific time format 141570af302Sopenharmony_ci * @tc.level : Level 0 142570af302Sopenharmony_ci */ 143570af302Sopenharmony_civoid strptime_0500(void) 144570af302Sopenharmony_ci{ 145570af302Sopenharmony_ci const char *buffer = "16"; 146570af302Sopenharmony_ci struct tm tmTime = {0}; 147570af302Sopenharmony_ci strptime(buffer, " %k", &tmTime); 148570af302Sopenharmony_ci char buffResult[gBufferSize]; 149570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d", tmTime.tm_hour); 150570af302Sopenharmony_ci EXPECT_TRUE("strptime_0500", cnt > 0); 151570af302Sopenharmony_ci EXPECT_STREQ("strptime_0500", buffer, buffResult); 152570af302Sopenharmony_ci} 153570af302Sopenharmony_ci 154570af302Sopenharmony_ci/** 155570af302Sopenharmony_ci * @tc.name : strptime_0600 156570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 157570af302Sopenharmony_ci * type according to a specific time format 158570af302Sopenharmony_ci * @tc.level : Level 0 159570af302Sopenharmony_ci */ 160570af302Sopenharmony_civoid strptime_0600(void) 161570af302Sopenharmony_ci{ 162570af302Sopenharmony_ci const char *buffer = " 4"; 163570af302Sopenharmony_ci struct tm tmTime = {0}; 164570af302Sopenharmony_ci strptime(buffer, " %l", &tmTime); 165570af302Sopenharmony_ci char buffResult[gBufferSize]; 166570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d", tmTime.tm_hour); 167570af302Sopenharmony_ci EXPECT_TRUE("strptime_0600", cnt > 0); 168570af302Sopenharmony_ci EXPECT_STREQ("strptime_0600", "4", buffResult); 169570af302Sopenharmony_ci} 170570af302Sopenharmony_ci 171570af302Sopenharmony_ci/** 172570af302Sopenharmony_ci * @tc.name : strptime_0700 173570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 174570af302Sopenharmony_ci * type according to a specific time format 175570af302Sopenharmony_ci * @tc.level : Level 0 176570af302Sopenharmony_ci */ 177570af302Sopenharmony_civoid strptime_0700(void) 178570af302Sopenharmony_ci{ 179570af302Sopenharmony_ci const char *buffer = "1659177614"; 180570af302Sopenharmony_ci const char *handlerChar = test_handle_path(test_asctime_data[0].tz); 181570af302Sopenharmony_ci if (!handlerChar) { 182570af302Sopenharmony_ci t_error("strptime_0700 failed: handlerChar is NULL\n"); 183570af302Sopenharmony_ci return; 184570af302Sopenharmony_ci } 185570af302Sopenharmony_ci 186570af302Sopenharmony_ci setenv("TZ", handlerChar, 1); 187570af302Sopenharmony_ci time_t second = 0; 188570af302Sopenharmony_ci struct tm tmTime = {0}; 189570af302Sopenharmony_ci strptime(buffer, "%s", &tmTime); 190570af302Sopenharmony_ci second = mktime(&tmTime); 191570af302Sopenharmony_ci char buffResult[gBufferSize]; 192570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%lld", second); 193570af302Sopenharmony_ci EXPECT_TRUE("strptime_0700", cnt > 0); 194570af302Sopenharmony_ci EXPECT_STREQ("strptime_0700", buffer, buffResult); 195570af302Sopenharmony_ci} 196570af302Sopenharmony_ci 197570af302Sopenharmony_ci/** 198570af302Sopenharmony_ci * @tc.name : strptime_0800 199570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 200570af302Sopenharmony_ci * type according to a specific time format 201570af302Sopenharmony_ci * @tc.level : Level 0 202570af302Sopenharmony_ci */ 203570af302Sopenharmony_civoid strptime_0800(void) 204570af302Sopenharmony_ci{ 205570af302Sopenharmony_ci const char *buffer = "1"; 206570af302Sopenharmony_ci struct tm tmTime = {0}; 207570af302Sopenharmony_ci strptime(buffer, "%u", &tmTime); 208570af302Sopenharmony_ci char buffResult[gBufferSize]; 209570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d", tmTime.tm_wday); 210570af302Sopenharmony_ci EXPECT_TRUE("strptime_0800", cnt > 0); 211570af302Sopenharmony_ci EXPECT_STREQ("strptime_0800", buffer, buffResult); 212570af302Sopenharmony_ci} 213570af302Sopenharmony_ci 214570af302Sopenharmony_ci/** 215570af302Sopenharmony_ci * @tc.name : strptime_0900 216570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 217570af302Sopenharmony_ci * type according to a specific time format 218570af302Sopenharmony_ci * @tc.level : Level 0 219570af302Sopenharmony_ci */ 220570af302Sopenharmony_civoid strptime_0900(void) 221570af302Sopenharmony_ci{ 222570af302Sopenharmony_ci const char *buffer = "30-Oct-2021"; 223570af302Sopenharmony_ci struct tm tmTime = {0}; 224570af302Sopenharmony_ci strptime(buffer, "%v", &tmTime); 225570af302Sopenharmony_ci char buffResult[gBufferSize]; 226570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d-%d-%d", 227570af302Sopenharmony_ci (tmTime.tm_year+gYearBase), tmTime.tm_mon, tmTime.tm_mday); 228570af302Sopenharmony_ci EXPECT_TRUE("strptime_0900", cnt > 0); 229570af302Sopenharmony_ci EXPECT_STREQ("strptime_0900", "2021-9-30", buffResult); 230570af302Sopenharmony_ci} 231570af302Sopenharmony_ci 232570af302Sopenharmony_ci/** 233570af302Sopenharmony_ci * @tc.name : strptime_1000 234570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 235570af302Sopenharmony_ci * type according to a specific time format 236570af302Sopenharmony_ci * @tc.level : Level 1 237570af302Sopenharmony_ci */ 238570af302Sopenharmony_civoid strptime_1000(void) 239570af302Sopenharmony_ci{ 240570af302Sopenharmony_ci const char *buffer = "2021-01-23"; 241570af302Sopenharmony_ci struct tm tmTime = {0}; 242570af302Sopenharmony_ci char *result = strptime(buffer, "%G", &tmTime); 243570af302Sopenharmony_ci char buffResult[gBufferSize]; 244570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%s", result); 245570af302Sopenharmony_ci EXPECT_TRUE("strptime_1000", cnt > 0); 246570af302Sopenharmony_ci EXPECT_STREQ("strptime_1000", "-01-23", buffResult); 247570af302Sopenharmony_ci} 248570af302Sopenharmony_ci 249570af302Sopenharmony_ci/** 250570af302Sopenharmony_ci * @tc.name : strptime_1100 251570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 252570af302Sopenharmony_ci * type according to a specific time format 253570af302Sopenharmony_ci * @tc.level : Level 1 254570af302Sopenharmony_ci */ 255570af302Sopenharmony_civoid strptime_1100(void) 256570af302Sopenharmony_ci{ 257570af302Sopenharmony_ci const char *buffer = "23"; 258570af302Sopenharmony_ci struct tm tmTime = {0}; 259570af302Sopenharmony_ci strptime(buffer, "%j", &tmTime); 260570af302Sopenharmony_ci char buffResult[gBufferSize]; 261570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d", tmTime.tm_yday); 262570af302Sopenharmony_ci EXPECT_TRUE("strptime_1100", cnt > 0); 263570af302Sopenharmony_ci EXPECT_STREQ("strptime_1100", "22", buffResult); 264570af302Sopenharmony_ci} 265570af302Sopenharmony_ci 266570af302Sopenharmony_ci/** 267570af302Sopenharmony_ci * @tc.name : strptime_1200 268570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 269570af302Sopenharmony_ci * type according to a specific time format 270570af302Sopenharmony_ci * @tc.level : Level 0 271570af302Sopenharmony_ci */ 272570af302Sopenharmony_civoid strptime_1200(void) 273570af302Sopenharmony_ci{ 274570af302Sopenharmony_ci const char *buffer = "am"; 275570af302Sopenharmony_ci const char *handlerChar = test_handle_path("Asia/Shanghai"); 276570af302Sopenharmony_ci if (!handlerChar) { 277570af302Sopenharmony_ci t_error("strptime_1200 failed: handlerChar is NULL\n"); 278570af302Sopenharmony_ci return; 279570af302Sopenharmony_ci } 280570af302Sopenharmony_ci 281570af302Sopenharmony_ci setenv("TZ", handlerChar, 1); 282570af302Sopenharmony_ci tzset(); 283570af302Sopenharmony_ci struct tm *timeptr = localtime(&gTime); 284570af302Sopenharmony_ci if (!timeptr) { 285570af302Sopenharmony_ci EXPECT_PTRNE("strptime_1200", timeptr, NULL); 286570af302Sopenharmony_ci return; 287570af302Sopenharmony_ci } 288570af302Sopenharmony_ci strptime(buffer, "%P", timeptr); 289570af302Sopenharmony_ci char buffResult[gBufferSize]; 290570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d", timeptr->tm_hour); 291570af302Sopenharmony_ci EXPECT_TRUE("strptime_1200", cnt > 0); 292570af302Sopenharmony_ci EXPECT_STREQ("strptime_1200", "6", buffResult); 293570af302Sopenharmony_ci} 294570af302Sopenharmony_ci 295570af302Sopenharmony_ci/** 296570af302Sopenharmony_ci * @tc.name : strptime_1300 297570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 298570af302Sopenharmony_ci * type according to a specific time format 299570af302Sopenharmony_ci * @tc.level : Level 0 300570af302Sopenharmony_ci */ 301570af302Sopenharmony_civoid strptime_1300(void) 302570af302Sopenharmony_ci{ 303570af302Sopenharmony_ci const char *buffer = "pm"; 304570af302Sopenharmony_ci const char *handlerChar = test_handle_path("Asia/Shanghai"); 305570af302Sopenharmony_ci if (!handlerChar) { 306570af302Sopenharmony_ci t_error("strptime_1300 failed: handlerChar is NULL\n"); 307570af302Sopenharmony_ci return; 308570af302Sopenharmony_ci } 309570af302Sopenharmony_ci 310570af302Sopenharmony_ci setenv("TZ", handlerChar, 1); 311570af302Sopenharmony_ci tzset(); 312570af302Sopenharmony_ci struct tm *timeptr = localtime(&gTime); 313570af302Sopenharmony_ci if (!timeptr) { 314570af302Sopenharmony_ci EXPECT_PTRNE("strptime_1300", timeptr, NULL); 315570af302Sopenharmony_ci return; 316570af302Sopenharmony_ci } 317570af302Sopenharmony_ci strptime(buffer, "%P", timeptr); 318570af302Sopenharmony_ci char buffResult[gBufferSize]; 319570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d", timeptr->tm_hour); 320570af302Sopenharmony_ci EXPECT_TRUE("strptime_1300", cnt > 0); 321570af302Sopenharmony_ci EXPECT_STREQ("strptime_1300", "18", buffResult); 322570af302Sopenharmony_ci} 323570af302Sopenharmony_ci 324570af302Sopenharmony_ci/** 325570af302Sopenharmony_ci * @tc.name : strptime_1400 326570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 327570af302Sopenharmony_ci * type according to a specific time format 328570af302Sopenharmony_ci * @tc.level : Level 0 329570af302Sopenharmony_ci */ 330570af302Sopenharmony_civoid strptime_1400(void) 331570af302Sopenharmony_ci{ 332570af302Sopenharmony_ci const char *buffer = "30-Oct-2021"; 333570af302Sopenharmony_ci struct tm tmTime = {0}; 334570af302Sopenharmony_ci char *result = strptime(buffer, "%U", &tmTime); 335570af302Sopenharmony_ci char buffResult[gBufferSize]; 336570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%s", result); 337570af302Sopenharmony_ci EXPECT_TRUE("strptime_1400", cnt > 0); 338570af302Sopenharmony_ci EXPECT_STREQ("strptime_1400", "-Oct-2021", buffResult); 339570af302Sopenharmony_ci} 340570af302Sopenharmony_ci 341570af302Sopenharmony_ci/** 342570af302Sopenharmony_ci * @tc.name : strptime_1500 343570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 344570af302Sopenharmony_ci * type according to a specific time format 345570af302Sopenharmony_ci * @tc.level : Level 0 346570af302Sopenharmony_ci */ 347570af302Sopenharmony_civoid strptime_1500(void) 348570af302Sopenharmony_ci{ 349570af302Sopenharmony_ci const char *buffer = "1"; 350570af302Sopenharmony_ci struct tm tmTime = {0}; 351570af302Sopenharmony_ci char *result = strptime(buffer, "%w", &tmTime); 352570af302Sopenharmony_ci char buffResult[gBufferSize]; 353570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d", tmTime.tm_wday); 354570af302Sopenharmony_ci EXPECT_TRUE("strptime_1500", cnt > 0); 355570af302Sopenharmony_ci EXPECT_STREQ("strptime_1500", "1", buffResult); 356570af302Sopenharmony_ci} 357570af302Sopenharmony_ci 358570af302Sopenharmony_ci/** 359570af302Sopenharmony_ci * @tc.name : strptime_1600 360570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 361570af302Sopenharmony_ci * type according to a specific time format 362570af302Sopenharmony_ci * @tc.level : Level 0 363570af302Sopenharmony_ci */ 364570af302Sopenharmony_civoid strptime_1600(void) 365570af302Sopenharmony_ci{ 366570af302Sopenharmony_ci const char *buffer = "Oct-30-2021"; 367570af302Sopenharmony_ci struct tm tmTime = {0}; 368570af302Sopenharmony_ci strptime(buffer, "%v", &tmTime); 369570af302Sopenharmony_ci char buffResult[gBufferSize]; 370570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d-%d-%d", 371570af302Sopenharmony_ci (tmTime.tm_year+gYearBase), tmTime.tm_mon, tmTime.tm_mday); 372570af302Sopenharmony_ci EXPECT_TRUE("strptime_1600", cnt > 0); 373570af302Sopenharmony_ci EXPECT_STREQ("strptime_1600", "1900-0-0", buffResult); 374570af302Sopenharmony_ci} 375570af302Sopenharmony_ci 376570af302Sopenharmony_ci/** 377570af302Sopenharmony_ci * @tc.name : strptime_1700 378570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 379570af302Sopenharmony_ci * type according to a specific time format 380570af302Sopenharmony_ci * @tc.level : Level 0 381570af302Sopenharmony_ci */ 382570af302Sopenharmony_civoid strptime_1700(void) 383570af302Sopenharmony_ci{ 384570af302Sopenharmony_ci const char *buffer = "16-Spring"; 385570af302Sopenharmony_ci struct tm tmTime = {0}; 386570af302Sopenharmony_ci char *result = strptime(buffer, "%V", &tmTime); 387570af302Sopenharmony_ci char buffResult[gBufferSize]; 388570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%s", result); 389570af302Sopenharmony_ci EXPECT_TRUE("strptime_1700", cnt > 0); 390570af302Sopenharmony_ci EXPECT_STREQ("strptime_1700", "-Spring", buffResult); 391570af302Sopenharmony_ci} 392570af302Sopenharmony_ci 393570af302Sopenharmony_ci/** 394570af302Sopenharmony_ci * @tc.name : strptime_1800 395570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 396570af302Sopenharmony_ci * type according to a specific time format 397570af302Sopenharmony_ci * @tc.level : Level 1 398570af302Sopenharmony_ci */ 399570af302Sopenharmony_civoid strptime_1800(void) 400570af302Sopenharmony_ci{ 401570af302Sopenharmony_ci const char *buffer = "+03"; 402570af302Sopenharmony_ci struct tm tmTime = {0}; 403570af302Sopenharmony_ci char *result = strptime(buffer, "%Z", &tmTime); 404570af302Sopenharmony_ci char buffResult[gBufferSize]; 405570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%s", tmTime.__tm_zone); 406570af302Sopenharmony_ci EXPECT_TRUE("strptime_1800", cnt > 0); 407570af302Sopenharmony_ci EXPECT_STREQ("strptime_1800", "+03", buffResult); 408570af302Sopenharmony_ci} 409570af302Sopenharmony_ci 410570af302Sopenharmony_ci/** 411570af302Sopenharmony_ci * @tc.name : strptime_1900 412570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 413570af302Sopenharmony_ci * type according to a specific time format 414570af302Sopenharmony_ci * @tc.level : Level 1 415570af302Sopenharmony_ci */ 416570af302Sopenharmony_civoid strptime_1900(void) 417570af302Sopenharmony_ci{ 418570af302Sopenharmony_ci const char *buffer = "-03"; 419570af302Sopenharmony_ci struct tm tmTime = {0}; 420570af302Sopenharmony_ci char *result = strptime(buffer, "%Z", &tmTime); 421570af302Sopenharmony_ci char buffResult[gBufferSize]; 422570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%s", tmTime.__tm_zone); 423570af302Sopenharmony_ci EXPECT_TRUE("strptime_1900", cnt > 0); 424570af302Sopenharmony_ci EXPECT_STREQ("strptime_1900", "-03", buffResult); 425570af302Sopenharmony_ci} 426570af302Sopenharmony_ci 427570af302Sopenharmony_ci/** 428570af302Sopenharmony_ci * @tc.name : strptime_2000 429570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 430570af302Sopenharmony_ci * type according to a specific time format 431570af302Sopenharmony_ci * @tc.level : Level 2 432570af302Sopenharmony_ci */ 433570af302Sopenharmony_civoid strptime_2000(void) 434570af302Sopenharmony_ci{ 435570af302Sopenharmony_ci const char *buffer = "Oct-30-2021"; 436570af302Sopenharmony_ci struct tm tmTime = {0}; 437570af302Sopenharmony_ci char *result = strptime(buffer, "test", &tmTime); 438570af302Sopenharmony_ci EXPECT_FALSE("strptime_2000", result); 439570af302Sopenharmony_ci} 440570af302Sopenharmony_ci 441570af302Sopenharmony_ci/** 442570af302Sopenharmony_ci * @tc.name : strptime_2100 443570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 444570af302Sopenharmony_ci * type according to a specific time format 445570af302Sopenharmony_ci * @tc.level : Level 1 446570af302Sopenharmony_ci */ 447570af302Sopenharmony_civoid strptime_2100(void) 448570af302Sopenharmony_ci{ 449570af302Sopenharmony_ci const char *buffer = "2022-4-10"; 450570af302Sopenharmony_ci struct tm tmTime = {0}; 451570af302Sopenharmony_ci char *result = strptime(buffer, "%+2F", &tmTime); 452570af302Sopenharmony_ci char buffResult[gBufferSize]; 453570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d", tmTime.tm_mday); 454570af302Sopenharmony_ci EXPECT_TRUE("strptime_2100", cnt > 0); 455570af302Sopenharmony_ci EXPECT_STREQ("strptime_2100", "10", buffResult); 456570af302Sopenharmony_ci} 457570af302Sopenharmony_ci 458570af302Sopenharmony_ci/** 459570af302Sopenharmony_ci * @tc.name : strptime_2200 460570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 461570af302Sopenharmony_ci * type according to a specific time format 462570af302Sopenharmony_ci * @tc.level : Level 2 463570af302Sopenharmony_ci */ 464570af302Sopenharmony_civoid strptime_2200(void) 465570af302Sopenharmony_ci{ 466570af302Sopenharmony_ci const char *buffer = ""; 467570af302Sopenharmony_ci struct tm tmTime = {0}; 468570af302Sopenharmony_ci char *result = strptime(buffer, "%c", &tmTime); 469570af302Sopenharmony_ci EXPECT_FALSE("strptime_2200", result); 470570af302Sopenharmony_ci} 471570af302Sopenharmony_ci 472570af302Sopenharmony_ci/** 473570af302Sopenharmony_ci * @tc.name : strptime_2300 474570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 475570af302Sopenharmony_ci * type according to a specific time format 476570af302Sopenharmony_ci * @tc.level : Level 1 477570af302Sopenharmony_ci */ 478570af302Sopenharmony_civoid strptime_2300(void) 479570af302Sopenharmony_ci{ 480570af302Sopenharmony_ci const char *buffer = "2022"; 481570af302Sopenharmony_ci struct tm tmTime = {0}; 482570af302Sopenharmony_ci char *result = strptime(buffer, "%C", &tmTime); 483570af302Sopenharmony_ci char buffResult[gBufferSize]; 484570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%s", result); 485570af302Sopenharmony_ci EXPECT_TRUE("strptime_2300", cnt > 0); 486570af302Sopenharmony_ci EXPECT_STREQ("strptime_2300", "22", buffResult); 487570af302Sopenharmony_ci} 488570af302Sopenharmony_ci 489570af302Sopenharmony_ci/** 490570af302Sopenharmony_ci * @tc.name : strptime_2400 491570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 492570af302Sopenharmony_ci * type according to a specific time format 493570af302Sopenharmony_ci * @tc.level : Level 2 494570af302Sopenharmony_ci */ 495570af302Sopenharmony_civoid strptime_2400(void) 496570af302Sopenharmony_ci{ 497570af302Sopenharmony_ci const char *buffer = ""; 498570af302Sopenharmony_ci struct tm tmTime = {0}; 499570af302Sopenharmony_ci char *result = strptime(buffer, "%D", &tmTime); 500570af302Sopenharmony_ci EXPECT_FALSE("strptime_2400", result); 501570af302Sopenharmony_ci} 502570af302Sopenharmony_ci 503570af302Sopenharmony_ci/** 504570af302Sopenharmony_ci * @tc.name : strptime_2500 505570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 506570af302Sopenharmony_ci * type according to a specific time format 507570af302Sopenharmony_ci * @tc.level : Level 2 508570af302Sopenharmony_ci */ 509570af302Sopenharmony_civoid strptime_2500(void) 510570af302Sopenharmony_ci{ 511570af302Sopenharmony_ci const char *buffer = ""; 512570af302Sopenharmony_ci struct tm tmTime = {0}; 513570af302Sopenharmony_ci char *result = strptime(buffer, "%F", &tmTime); 514570af302Sopenharmony_ci EXPECT_FALSE("strptime_2500", result); 515570af302Sopenharmony_ci} 516570af302Sopenharmony_ci 517570af302Sopenharmony_ci/** 518570af302Sopenharmony_ci * @tc.name : strptime_2600 519570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 520570af302Sopenharmony_ci * type according to a specific time format 521570af302Sopenharmony_ci * @tc.level : Level 1 522570af302Sopenharmony_ci */ 523570af302Sopenharmony_civoid strptime_2600(void) 524570af302Sopenharmony_ci{ 525570af302Sopenharmony_ci const char *buffer = " 1"; 526570af302Sopenharmony_ci struct tm tmTime = {0}; 527570af302Sopenharmony_ci char *result = strptime(buffer, "%n%t", &tmTime); 528570af302Sopenharmony_ci char buffResult[gBufferSize]; 529570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%s", result); 530570af302Sopenharmony_ci EXPECT_TRUE("strptime_2600", cnt > 0); 531570af302Sopenharmony_ci EXPECT_STREQ("strptime_2600", "1", buffResult); 532570af302Sopenharmony_ci} 533570af302Sopenharmony_ci 534570af302Sopenharmony_ci/** 535570af302Sopenharmony_ci * @tc.name : strptime_2700 536570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 537570af302Sopenharmony_ci * type according to a specific time format 538570af302Sopenharmony_ci * @tc.level : Level 1 539570af302Sopenharmony_ci */ 540570af302Sopenharmony_civoid strptime_2700(void) 541570af302Sopenharmony_ci{ 542570af302Sopenharmony_ci const char *buffer = "08:38:20"; 543570af302Sopenharmony_ci struct tm tmTime = {0}; 544570af302Sopenharmony_ci char *result = strptime(buffer, "%r", &tmTime); 545570af302Sopenharmony_ci char buffResult[gBufferSize]; 546570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d:%d:%d", tmTime.tm_hour, tmTime.tm_min, tmTime.tm_sec); 547570af302Sopenharmony_ci EXPECT_TRUE("strptime_2700", cnt > 0); 548570af302Sopenharmony_ci EXPECT_STREQ("strptime_2700", "8:38:20", buffResult); 549570af302Sopenharmony_ci} 550570af302Sopenharmony_ci 551570af302Sopenharmony_ci/** 552570af302Sopenharmony_ci * @tc.name : strptime_2800 553570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 554570af302Sopenharmony_ci * type according to a specific time format 555570af302Sopenharmony_ci * @tc.level : Level 2 556570af302Sopenharmony_ci */ 557570af302Sopenharmony_civoid strptime_2800(void) 558570af302Sopenharmony_ci{ 559570af302Sopenharmony_ci const char *buffer = ""; 560570af302Sopenharmony_ci struct tm tmTime = {0}; 561570af302Sopenharmony_ci char *result = strptime(buffer, "%r", &tmTime); 562570af302Sopenharmony_ci EXPECT_FALSE("strptime_2800", result); 563570af302Sopenharmony_ci} 564570af302Sopenharmony_ci 565570af302Sopenharmony_ci/** 566570af302Sopenharmony_ci * @tc.name : strptime_2900 567570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 568570af302Sopenharmony_ci * type according to a specific time format 569570af302Sopenharmony_ci * @tc.level : Level 2 570570af302Sopenharmony_ci */ 571570af302Sopenharmony_civoid strptime_2900(void) 572570af302Sopenharmony_ci{ 573570af302Sopenharmony_ci const char *buffer = ""; 574570af302Sopenharmony_ci struct tm tmTime = {0}; 575570af302Sopenharmony_ci char *result = strptime(buffer, "%R", &tmTime); 576570af302Sopenharmony_ci EXPECT_FALSE("strptime_2900", result); 577570af302Sopenharmony_ci} 578570af302Sopenharmony_ci 579570af302Sopenharmony_ci/** 580570af302Sopenharmony_ci * @tc.name : strptime_3000 581570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 582570af302Sopenharmony_ci * type according to a specific time format 583570af302Sopenharmony_ci * @tc.level : Level 2 584570af302Sopenharmony_ci */ 585570af302Sopenharmony_civoid strptime_3000(void) 586570af302Sopenharmony_ci{ 587570af302Sopenharmony_ci const char *buffer = "+1"; 588570af302Sopenharmony_ci struct tm tmTime = {0}; 589570af302Sopenharmony_ci char *result = strptime(buffer, "%s", &tmTime); 590570af302Sopenharmony_ci EXPECT_FALSE("strptime_3000", result); 591570af302Sopenharmony_ci} 592570af302Sopenharmony_ci 593570af302Sopenharmony_ci/** 594570af302Sopenharmony_ci * @tc.name : strptime_3100 595570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 596570af302Sopenharmony_ci * type according to a specific time format 597570af302Sopenharmony_ci * @tc.level : Level 2 598570af302Sopenharmony_ci */ 599570af302Sopenharmony_civoid strptime_3100(void) 600570af302Sopenharmony_ci{ 601570af302Sopenharmony_ci const char *buffer = ""; 602570af302Sopenharmony_ci struct tm tmTime = {0}; 603570af302Sopenharmony_ci char *result = strptime(buffer, "%T", &tmTime); 604570af302Sopenharmony_ci EXPECT_FALSE("strptime_3100", result); 605570af302Sopenharmony_ci} 606570af302Sopenharmony_ci 607570af302Sopenharmony_ci/** 608570af302Sopenharmony_ci * @tc.name : strptime_3200 609570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 610570af302Sopenharmony_ci * type according to a specific time format 611570af302Sopenharmony_ci * @tc.level : Level 2 612570af302Sopenharmony_ci */ 613570af302Sopenharmony_civoid strptime_3200(void) 614570af302Sopenharmony_ci{ 615570af302Sopenharmony_ci const char *buffer = ""; 616570af302Sopenharmony_ci struct tm tmTime = {0}; 617570af302Sopenharmony_ci char *result = strptime(buffer, "%u", &tmTime); 618570af302Sopenharmony_ci EXPECT_FALSE("strptime_3200", result); 619570af302Sopenharmony_ci} 620570af302Sopenharmony_ci 621570af302Sopenharmony_ci/** 622570af302Sopenharmony_ci * @tc.name : strptime_3300 623570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 624570af302Sopenharmony_ci * type according to a specific time format 625570af302Sopenharmony_ci * @tc.level : Level 2 626570af302Sopenharmony_ci */ 627570af302Sopenharmony_civoid strptime_3300(void) 628570af302Sopenharmony_ci{ 629570af302Sopenharmony_ci const char *buffer = ""; 630570af302Sopenharmony_ci struct tm tmTime = {0}; 631570af302Sopenharmony_ci char *result = strptime(buffer, "%V", &tmTime); 632570af302Sopenharmony_ci EXPECT_FALSE("strptime_3300", result); 633570af302Sopenharmony_ci} 634570af302Sopenharmony_ci 635570af302Sopenharmony_ci/** 636570af302Sopenharmony_ci * @tc.name : strptime_3400 637570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 638570af302Sopenharmony_ci * type according to a specific time format 639570af302Sopenharmony_ci * @tc.level : Level 1 640570af302Sopenharmony_ci */ 641570af302Sopenharmony_civoid strptime_3400(void) 642570af302Sopenharmony_ci{ 643570af302Sopenharmony_ci const char *buffer = "04/10/22"; 644570af302Sopenharmony_ci struct tm tmTime = {0}; 645570af302Sopenharmony_ci char *result = strptime(buffer, "%x", &tmTime); 646570af302Sopenharmony_ci char buffResult[gBufferSize]; 647570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d/%d/%d", (tmTime.tm_mon + 1), tmTime.tm_mday, (tmTime.tm_year + gYearBase)); 648570af302Sopenharmony_ci EXPECT_TRUE("strptime_3400", cnt > 0); 649570af302Sopenharmony_ci EXPECT_STREQ("strptime_3400", "4/10/2022", buffResult); 650570af302Sopenharmony_ci} 651570af302Sopenharmony_ci 652570af302Sopenharmony_ci/** 653570af302Sopenharmony_ci * @tc.name : strptime_3500 654570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 655570af302Sopenharmony_ci * type according to a specific time format 656570af302Sopenharmony_ci * @tc.level : Level 2 657570af302Sopenharmony_ci */ 658570af302Sopenharmony_civoid strptime_3500(void) 659570af302Sopenharmony_ci{ 660570af302Sopenharmony_ci const char *buffer = ""; 661570af302Sopenharmony_ci struct tm tmTime = {0}; 662570af302Sopenharmony_ci char *result = strptime(buffer, "%x", &tmTime); 663570af302Sopenharmony_ci EXPECT_FALSE("strptime_3500", result); 664570af302Sopenharmony_ci} 665570af302Sopenharmony_ci 666570af302Sopenharmony_ci/** 667570af302Sopenharmony_ci * @tc.name : strptime_3600 668570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 669570af302Sopenharmony_ci * type according to a specific time format 670570af302Sopenharmony_ci * @tc.level : Level 1 671570af302Sopenharmony_ci */ 672570af302Sopenharmony_civoid strptime_3600(void) 673570af302Sopenharmony_ci{ 674570af302Sopenharmony_ci const char *buffer = "08:10:20"; 675570af302Sopenharmony_ci struct tm tmTime = {0}; 676570af302Sopenharmony_ci char *result = strptime(buffer, "%X", &tmTime); 677570af302Sopenharmony_ci char buffResult[gBufferSize]; 678570af302Sopenharmony_ci int cnt = sprintf(buffResult, "%d:%d:%d", tmTime.tm_hour, tmTime.tm_min, tmTime.tm_sec); 679570af302Sopenharmony_ci EXPECT_TRUE("strptime_3600", cnt > 0); 680570af302Sopenharmony_ci EXPECT_STREQ("strptime_3600", "8:10:20", buffResult); 681570af302Sopenharmony_ci} 682570af302Sopenharmony_ci 683570af302Sopenharmony_ci/** 684570af302Sopenharmony_ci * @tc.name : strptime_3700 685570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 686570af302Sopenharmony_ci * type according to a specific time format 687570af302Sopenharmony_ci * @tc.level : Level 2 688570af302Sopenharmony_ci */ 689570af302Sopenharmony_civoid strptime_3700(void) 690570af302Sopenharmony_ci{ 691570af302Sopenharmony_ci const char *buffer = ""; 692570af302Sopenharmony_ci struct tm tmTime = {0}; 693570af302Sopenharmony_ci char *result = strptime(buffer, "%X", &tmTime); 694570af302Sopenharmony_ci EXPECT_FALSE("strptime_3700", result); 695570af302Sopenharmony_ci} 696570af302Sopenharmony_ci 697570af302Sopenharmony_ci/** 698570af302Sopenharmony_ci * @tc.name : strptime_3800 699570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 700570af302Sopenharmony_ci * type according to a specific time format 701570af302Sopenharmony_ci * @tc.level : Level 2 702570af302Sopenharmony_ci */ 703570af302Sopenharmony_civoid strptime_3800(void) 704570af302Sopenharmony_ci{ 705570af302Sopenharmony_ci const char *buffer = ""; 706570af302Sopenharmony_ci struct tm tmTime = {0}; 707570af302Sopenharmony_ci char *result = strptime(buffer, "%%", &tmTime); 708570af302Sopenharmony_ci EXPECT_FALSE("strptime_3800", result); 709570af302Sopenharmony_ci} 710570af302Sopenharmony_ci 711570af302Sopenharmony_ci/** 712570af302Sopenharmony_ci * @tc.name : strptime_3900 713570af302Sopenharmony_ci * @tc.desc : according to different time zones, convert a string to a time 714570af302Sopenharmony_ci * type according to a specific time format 715570af302Sopenharmony_ci * @tc.level : Level 2 716570af302Sopenharmony_ci */ 717570af302Sopenharmony_civoid strptime_3900(void) 718570af302Sopenharmony_ci{ 719570af302Sopenharmony_ci const char *buffer = ""; 720570af302Sopenharmony_ci struct tm tmTime = {0}; 721570af302Sopenharmony_ci char *result = strptime(buffer, "%&", &tmTime); 722570af302Sopenharmony_ci EXPECT_FALSE("strptime_3900", result); 723570af302Sopenharmony_ci} 724570af302Sopenharmony_ci 725570af302Sopenharmony_ciint main(void) 726570af302Sopenharmony_ci{ 727570af302Sopenharmony_ci strptime_0100(); 728570af302Sopenharmony_ci strptime_0200(); 729570af302Sopenharmony_ci strptime_0300(); 730570af302Sopenharmony_ci strptime_0400(); 731570af302Sopenharmony_ci strptime_0500(); 732570af302Sopenharmony_ci strptime_0600(); 733570af302Sopenharmony_ci strptime_0700(); 734570af302Sopenharmony_ci strptime_0800(); 735570af302Sopenharmony_ci strptime_0900(); 736570af302Sopenharmony_ci strptime_1000(); 737570af302Sopenharmony_ci strptime_1100(); 738570af302Sopenharmony_ci strptime_1200(); 739570af302Sopenharmony_ci strptime_1300(); 740570af302Sopenharmony_ci strptime_1400(); 741570af302Sopenharmony_ci strptime_1500(); 742570af302Sopenharmony_ci strptime_1600(); 743570af302Sopenharmony_ci strptime_1700(); 744570af302Sopenharmony_ci strptime_1800(); 745570af302Sopenharmony_ci strptime_1900(); 746570af302Sopenharmony_ci strptime_2000(); 747570af302Sopenharmony_ci strptime_2100(); 748570af302Sopenharmony_ci strptime_2200(); 749570af302Sopenharmony_ci strptime_2300(); 750570af302Sopenharmony_ci strptime_2400(); 751570af302Sopenharmony_ci strptime_2500(); 752570af302Sopenharmony_ci strptime_2600(); 753570af302Sopenharmony_ci strptime_2700(); 754570af302Sopenharmony_ci strptime_2800(); 755570af302Sopenharmony_ci strptime_2900(); 756570af302Sopenharmony_ci strptime_3000(); 757570af302Sopenharmony_ci strptime_3100(); 758570af302Sopenharmony_ci strptime_3200(); 759570af302Sopenharmony_ci strptime_3300(); 760570af302Sopenharmony_ci strptime_3400(); 761570af302Sopenharmony_ci strptime_3500(); 762570af302Sopenharmony_ci strptime_3600(); 763570af302Sopenharmony_ci strptime_3700(); 764570af302Sopenharmony_ci strptime_3800(); 765570af302Sopenharmony_ci strptime_3900(); 766570af302Sopenharmony_ci return t_status; 767570af302Sopenharmony_ci}