diff --git a/build_lite/BUILD.gn b/build_lite/BUILD.gn index 02bfec6b79bf363d17b1b93b6433d0ce66dde03d..2a736bbf5b9d7fb523b112e39593ef3295e86458 100644 --- a/build_lite/BUILD.gn +++ b/build_lite/BUILD.gn @@ -52,18 +52,18 @@ lite_component("acts_component") { "//test/xts/acts/utils_lite/kv_store_posix:ActsKvStoreTest", "//test/xts/acts/startup_lite/syspara_posix:ActsParameterTest", "//test/xts/acts/startup_lite/bootstrap_posix:ActsBootstrapTest", - "//test/xts/acts/multimedia_lite/camera_lite_posix/camera_native:ActsMediaCameraTest", "//test/xts/acts/open_posix_testsuite/conformance/interfaces:ActsOpenPosixTest", + "//test/xts/acts/multimedia_lite/camera_lite_posix/camera_native:ActsMediaCameraTest", "//test/xts/acts/multimedia_lite/media_lite_posix/player_native:ActsMediaPlayerTest", + "//test/xts/acts/multimedia_lite/media_lite_posix/recorder_native:ActsMediaRecorderTest", "//test/xts/acts/multimedia_lite/media_lite_posix/audio_native:ActsMediaAudioTest", + "//test/xts/acts/distributed_schedule_lite/system_ability_manager_posix:ActsSamgrTest", #"//test/xts/acts/distributedschedule_lite/distributed_schedule_posix:ActsDMSTest", "//test/xts/acts/hiviewdfx_lite/hilog_posix:ActsHilogTest", - "//test/xts/acts/multimedia_lite/media_lite_posix/recorder_native:ActsMediaRecorderTest", - "//test/xts/acts/appexecfwk_lite/appexecfwk_posix:ActsBundleMgrTest", "//test/xts/acts/aafwk_lite/ability_posix:ActsAbilityMgrTest", "//test/xts/acts/communication_lite/lwip_posix:ActsLwipTest", diff --git a/multimedia_lite/media_lite_posix/recorder_native/src/ActsMediaRecorderTest.cpp b/multimedia_lite/media_lite_posix/recorder_native/src/ActsMediaRecorderTest.cpp index c5d8e63cc4be084f790fe929b35b9ee1d16062f0..ddbdfcc9b4fea49d76168f1d86acd180b7a76efc 100644 --- a/multimedia_lite/media_lite_posix/recorder_native/src/ActsMediaRecorderTest.cpp +++ b/multimedia_lite/media_lite_posix/recorder_native/src/ActsMediaRecorderTest.cpp @@ -82,6 +82,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Start_test_001, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Release(); delete recInstance; @@ -108,6 +109,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Start_test_002, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_NE(RET_OK, retStatus); retStatus = recInstance->Release(); delete recInstance; @@ -136,6 +138,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Pause_test_001, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Pause(); EXPECT_EQ(RET_OK, retStatus); @@ -166,6 +169,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Pause_test_002, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Pause(); EXPECT_EQ(RET_OK, retStatus); @@ -198,6 +202,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Resume_test_001, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Pause(); EXPECT_EQ(RET_OK, retStatus); @@ -230,6 +235,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Resume_test_002, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Pause(); EXPECT_EQ(RET_OK, retStatus); @@ -264,6 +270,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Stop_test_001, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Stop(true); EXPECT_EQ(RET_OK, retStatus); @@ -294,6 +301,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Stop_test_002, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Stop(true); EXPECT_EQ(RET_OK, retStatus); @@ -326,6 +334,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Reset_test_001, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Reset(); EXPECT_EQ(RET_OK, retStatus); @@ -356,6 +365,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Reset_test_002, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Reset(); EXPECT_EQ(RET_OK, retStatus); @@ -388,6 +398,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Release_test_001, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Release(); EXPECT_EQ(RET_OK, retStatus); @@ -417,6 +428,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_Release_test_002, Level1) retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Release(); EXPECT_EQ(RET_OK, retStatus); @@ -451,6 +463,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_SetFileSplitDuration_test_001, Leve retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->SetFileSplitDuration(type, timestamp, duration); EXPECT_EQ(RET_OK, retStatus); @@ -484,6 +497,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_SetFileSplitDuration_test_002, Leve retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->SetFileSplitDuration(type, timestamp, duration); EXPECT_EQ(RET_OK, retStatus); @@ -517,6 +531,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_SetFileSplitDuration_test_003, Leve retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->SetFileSplitDuration(type, timestamp, duration); EXPECT_EQ(RET_OK, retStatus); @@ -550,6 +565,7 @@ HWTEST_F(RecoderLiteTest, medialite_recorder_SetFileSplitDuration_test_004, Leve retStatus = recInstance->SetRecorderCallback(cb); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Start(); + sleep(1); EXPECT_EQ(RET_OK, retStatus); retStatus = recInstance->Pause(); EXPECT_EQ(RET_OK, retStatus);