diff --git a/testsuites/unittest/posix/src/time/time_func_test_01.c b/testsuites/unittest/posix/src/time/time_func_test_01.c index a11a4c69..474d4f04 100644 --- a/testsuites/unittest/posix/src/time/time_func_test_01.c +++ b/testsuites/unittest/posix/src/time/time_func_test_01.c @@ -516,8 +516,8 @@ LITE_TEST_CASE(PosixTimeFuncTestSuite, testTimeStrftime003, Function | MediumTes */ LITE_TEST_CASE(PosixTimeFuncTestSuite, testTimes, Function | MediumTest | Level1) { - const int testClockt = 100; - const int msPerClock = 10; + const int testClockt = LOSCFG_BASE_CORE_TICK_PER_SECOND; + const int msPerClock = OS_SYS_MS_PER_SECOND / LOSCFG_BASE_CORE_TICK_PER_SECOND; struct tms start = { 0 }; struct tms end = { 0 }; clock_t stTime = times(&start); @@ -562,6 +562,6 @@ void PosixTimeFuncTest() RUN_ONE_TESTCASE(testTimeStrftime001); RUN_ONE_TESTCASE(testTimeStrftime002); RUN_ONE_TESTCASE(testTimeStrftime003); - + RUN_ONE_TESTCASE(testTimes); return; }