Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1275)

Side by Side Diff: ppapi/proxy/video_encoder_resource_unittest.cc

Issue 1469783002: Cleanup: Correctly spell success(ful). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: git cl format media Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ppapi/c/ppb_compositor.h ('k') | printing/backend/print_backend_cups.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/memory/shared_memory.h" 5 #include "base/memory/shared_memory.h"
6 #include "base/process/process.h" 6 #include "base/process/process.h"
7 #include "base/synchronization/waitable_event.h" 7 #include "base/synchronization/waitable_event.h"
8 #include "ppapi/c/pp_codecs.h" 8 #include "ppapi/c/pp_codecs.h"
9 #include "ppapi/c/pp_errors.h" 9 #include "ppapi/c/pp_errors.h"
10 #include "ppapi/c/ppb_video_encoder.h" 10 #include "ppapi/c/ppb_video_encoder.h"
(...skipping 625 matching lines...) Expand 10 before | Expand all | Expand 10 after
636 ResourceMessageCallParams error_params(encoder.get(), 0); 636 ResourceMessageCallParams error_params(encoder.get(), 0);
637 SendNotifyError(error_params, PP_ERROR_FAILED); 637 SendNotifyError(error_params, PP_ERROR_FAILED);
638 ASSERT_TRUE(cb.called()); 638 ASSERT_TRUE(cb.called());
639 ASSERT_EQ(PP_ERROR_FAILED, cb.result()); 639 ASSERT_EQ(PP_ERROR_FAILED, cb.result());
640 } 640 }
641 } 641 }
642 642
643 TEST_F(VideoEncoderResourceTest, InitializeSuccess) { 643 TEST_F(VideoEncoderResourceTest, InitializeSuccess) {
644 { 644 {
645 // Verify the initialize callback is called when initialization is 645 // Verify the initialize callback is called when initialization is
646 // successfull. 646 // successful.
647 LockingResourceReleaser encoder(CreateEncoder()); 647 LockingResourceReleaser encoder(CreateEncoder());
648 ResourceMessageCallParams params; 648 ResourceMessageCallParams params;
649 PP_Size size = kFrameSize; 649 PP_Size size = kFrameSize;
650 const uint32_t kBitrate = 420000; 650 const uint32_t kBitrate = 420000;
651 MockCompletionCallback cb; 651 MockCompletionCallback cb;
652 int32_t result = encoder_iface()->Initialize( 652 int32_t result = encoder_iface()->Initialize(
653 encoder.get(), PP_VIDEOFRAME_FORMAT_I420, &size, 653 encoder.get(), PP_VIDEOFRAME_FORMAT_I420, &size,
654 PP_VIDEOPROFILE_H264MAIN, kBitrate, 654 PP_VIDEOPROFILE_H264MAIN, kBitrate,
655 PP_HARDWAREACCELERATION_WITHFALLBACK, 655 PP_HARDWAREACCELERATION_WITHFALLBACK,
656 PP_MakeOptionalCompletionCallback(&MockCompletionCallback::Callback, 656 PP_MakeOptionalCompletionCallback(&MockCompletionCallback::Callback,
(...skipping 485 matching lines...) Expand 10 before | Expand all | Expand 10 after
1142 ResourceMessageCallParams params; 1142 ResourceMessageCallParams params;
1143 uint32_t frame_id; 1143 uint32_t frame_id;
1144 bool force_frame; 1144 bool force_frame;
1145 ASSERT_TRUE(CheckEncodeMsg(&params, &frame_id, &force_frame)); 1145 ASSERT_TRUE(CheckEncodeMsg(&params, &frame_id, &force_frame));
1146 SendEncodeReply(params, frame_id); 1146 SendEncodeReply(params, frame_id);
1147 } 1147 }
1148 } 1148 }
1149 1149
1150 } // namespace proxy 1150 } // namespace proxy
1151 } // namespace ppapi 1151 } // namespace ppapi
OLDNEW
« no previous file with comments | « ppapi/c/ppb_compositor.h ('k') | printing/backend/print_backend_cups.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698