shithub: openh264

Download patch

ref: e7debe7351bdaede93e76f43bd4b730419a8be77
parent: 59e782a8a57151768884d965088b66079026f479
parent: b9dc310857cff18655e38776ebcf5d4044d1ad6b
author: sijchen <[email protected]>
date: Fri Nov 28 05:28:05 EST 2014

Merge pull request #1571 from mstorsjo/silence-intentional-errors

Silence logging in a test which intentionally can trigger errors

--- a/test/encoder/EncUT_EncoderExt.cpp
+++ b/test/encoder/EncUT_EncoderExt.cpp
@@ -143,7 +143,10 @@
 TEST_F (EncoderInterfaceTest, EncoderAdditionalOptionSetTest) {
   int iResult, iValue, iReturn;
   float fValue, fReturn;
+  int uiTraceLevel = WELS_LOG_QUIET;
 
+  pPtrEnc->SetOption (ENCODER_OPTION_TRACE_LEVEL, &uiTraceLevel);
+
   InitializeParamExt();
   iResult = pPtrEnc->InitializeExt (pParamExt);
   EXPECT_EQ (iResult, static_cast<int> (cmResultSuccess));
@@ -255,6 +258,9 @@
   iResult = pPtrEnc->EncodeFrame (pSrcPic, &sFbi);
   EXPECT_EQ (iResult, static_cast<int> (cmResultSuccess));
   pSrcPic->uiTimeStamp += 30;
+
+  uiTraceLevel = WELS_LOG_ERROR;
+  pPtrEnc->SetOption (ENCODER_OPTION_TRACE_LEVEL, &uiTraceLevel);
 }
 
 TEST_F (EncoderInterfaceTest, TemporalLayerSettingTest) {