Популярное

Музыка Кино и Анимация Автомобили Животные Спорт Путешествия Игры Юмор

Интересные видео

2025 Сериалы Трейлеры Новости Как сделать Видеоуроки Diy своими руками

Топ запросов

смотреть а4 schoolboy runaway турецкий сериал смотреть мультфильмы эдисон
dTub
Скачать

Google Test and Mock Platform - Part 3: Mocking Classes and Functions with GMock

Автор: arisaif

Загружено: 2022-03-11

Просмотров: 38330

Описание:

In this video, we cover mocking classes and functions with GMock. This is a complete tutorial on GMock and is the third video in the video series of a complete tutorial on Google Test (GTest) and Google Mock (GMock) for writing unit tests in C++.
-----------------------------------------------------
Link to Part 1:    • Google Test and Mock Platform, Complete Tu...  
Link to Part 2:    • Google Test and Mock Platform - Part 2: GM...  
Link to the repo used in this video: https://github.com/ourarash/cpp-template.
A video describing how to use this repo:    • C++ starter repo for Bazel & Visual Studio...  
-----------------------------------------------------
Chapters:

Introduction 00:00
Mocking classes and functions: 02:34
Test Doubles 4:33
Example Test with Doubles 6:46
Spy vs. Mock 10:56
GMock Preview 12:36
Simple GMock Example 13:55
MOCK_METHOD macro 17:09
Specifying what the mock should do 18:47
Leave the mock behavior unspecified 20:37
What is ON_CALL macro 21:06
What is EXPECT_CALL macro 27:20
Cardinality in EXPECT_CALL 32:11
Uninteresting calls 37:19
NiceMock and StrictMock 39:13
Unexpected vs uninteresting calls 40:13
Sequencing in EXPECT_CALL 41:35
GMock Actions 47:04
GMock Actions: Return a value 48:33
GMock Actions: Side effects 49:56
GMock Actions: Invoke a function 52:48
Custom GMock Actions: 57:01
Sticky rules in GMock 58:11
Checkpoints 01:03:25
Mocking Private Methods 01:06:13
Mocking Overloaded Methods 01:06:30
Mocking Template Classes 01:06:47
Mocking Non-Virtual Classes 01:07:16
Mocking Free Functions 01:09:55
Delegating to Fake and Real in GMock 01:10:54
Criticisms of GMock 01:12:42

Let me know if you have any questions in the comments!
-----------------------------------------------------
See my other videos on:
How to use Google Benchmark for C++ Programs:    • How to use Google Benchmark for C++ programs  
Bazel and unit tests with GTest:    • Bazel & Google Test in Visual Studio Code  
Debugging in Visual Studio Code for C++:    • Debugging C++ in Visual Studio Code using ...  
Visual Studio Code, Top Features:    • Visual Studio Code Top Features 2020  
-----------------------------------------------------
Keep in touch with me:
  / ourarash  
  / ourarash  

I'm the founder of BitcoinCrazyness app, the Most Advanced Cryptocurrency mobile APP for alerts, Check it out:

http://www.bitcoincrazyness.com/

Google Test and Mock Platform - Part 3: Mocking Classes and Functions with GMock

Поделиться в:

Доступные форматы для скачивания:

Скачать видео mp4

  • Информация по загрузке:

Скачать аудио mp3

Похожие видео

array(10) { [0]=> object(stdClass)#9787 (5) { ["video_id"]=> int(9999999) ["related_video_id"]=> string(11) "JJqRlSTQlh4" ["related_video_title"]=> string(69) "Google Test and Mock Platform, Complete Tutorial. Part 1: Google Test" ["posted_time"]=> string(21) "3 года назад" ["channelName"]=> string(7) "arisaif" } [1]=> object(stdClass)#9760 (5) { ["video_id"]=> int(9999999) ["related_video_id"]=> string(11) "kLLDzLWzuag" ["related_video_title"]=> string(36) "Bazel Tutorial for C++ in 30 Minutes" ["posted_time"]=> string(21) "2 года назад" ["channelName"]=> string(7) "arisaif" } [2]=> object(stdClass)#9785 (5) { ["video_id"]=> int(9999999) ["related_video_id"]=> string(11) "3aqxaZsvn80" ["related_video_title"]=> string(39) "Learn C++ Multi Threading in 20 Minutes" ["posted_time"]=> string(19) "5 лет назад" ["channelName"]=> string(7) "arisaif" } [3]=> object(stdClass)#9792 (5) { ["video_id"]=> int(9999999) ["related_video_id"]=> string(11) "JfOzsBi_irY" ["related_video_title"]=> string(79) "C++ starter repo for Bazel & Visual Studio Code with GTest, Glog and Abseil" ["posted_time"]=> string(19) "5 лет назад" ["channelName"]=> string(7) "arisaif" } [4]=> object(stdClass)#9771 (5) { ["video_id"]=> int(9999999) ["related_video_id"]=> string(11) "TT-6-4OZp3c" ["related_video_title"]=> string(37) "C++ Command Line Arguments (Pro Tips)" ["posted_time"]=> string(21) "4 года назад" ["channelName"]=> string(7) "arisaif" } [5]=> object(stdClass)#9789 (5) { ["video_id"]=> int(9999999) ["related_video_id"]=> string(11) "as5Z45G59Ws" ["related_video_title"]=> string(93) "Refactoring C++ Code for Unit testing with Dependency Injection - Peter Muldoon - CppCon 2024" ["posted_time"]=> string(25) "4 месяца назад" ["channelName"]=> string(6) "CppCon" } [6]=> object(stdClass)#9784 (5) { ["video_id"]=> int(9999999) ["related_video_id"]=> string(11) "9VKR8u9odrA" ["related_video_title"]=> string(44) "How to use Google Benchmark for C++ programs" ["posted_time"]=> string(19) "5 лет назад" ["channelName"]=> string(7) "arisaif" } [7]=> object(stdClass)#9794 (5) { ["video_id"]=> int(9999999) ["related_video_id"]=> string(11) "blWdjRUPP6E" ["related_video_title"]=> string(72) "Разведчик о том, как использовать людей" ["posted_time"]=> string(25) "3 недели назад" ["channelName"]=> string(18) "Коллектив" } [8]=> object(stdClass)#9770 (5) { ["video_id"]=> int(9999999) ["related_video_id"]=> string(11) "YXRBBOjgrFU" ["related_video_title"]=> string(87) "16. Functional Interface and Lambda Expression - Java8 features | Java Interfaces Part3" ["posted_time"]=> string(19) "1 год назад" ["channelName"]=> string(32) "Concept && Coding - by Shrayansh" } [9]=> object(stdClass)#9788 (5) { ["video_id"]=> int(9999999) ["related_video_id"]=> string(11) "TxZwqVTaCmA" ["related_video_title"]=> string(80) "SOLID ПРИНЦИПЫ простым языком (много примеров)" ["posted_time"]=> string(21) "3 года назад" ["channelName"]=> string(7) "Ulbi TV" } }
Google Test and Mock Platform, Complete Tutorial. Part 1: Google Test

Google Test and Mock Platform, Complete Tutorial. Part 1: Google Test

Bazel Tutorial for C++ in 30 Minutes

Bazel Tutorial for C++ in 30 Minutes

Learn C++ Multi Threading in 20 Minutes

Learn C++ Multi Threading in 20 Minutes

C++ starter repo for Bazel & Visual Studio Code with GTest, Glog and Abseil

C++ starter repo for Bazel & Visual Studio Code with GTest, Glog and Abseil

C++ Command Line Arguments (Pro Tips)

C++ Command Line Arguments (Pro Tips)

Refactoring C++ Code for Unit testing with Dependency Injection - Peter Muldoon - CppCon 2024

Refactoring C++ Code for Unit testing with Dependency Injection - Peter Muldoon - CppCon 2024

How to use Google Benchmark for C++ programs

How to use Google Benchmark for C++ programs

Разведчик о том, как использовать людей

Разведчик о том, как использовать людей

16. Functional Interface and Lambda Expression - Java8 features | Java Interfaces Part3

16. Functional Interface and Lambda Expression - Java8 features | Java Interfaces Part3

SOLID ПРИНЦИПЫ простым языком (много примеров)

SOLID ПРИНЦИПЫ простым языком (много примеров)

© 2025 dtub. Все права защищены.



  • Контакты
  • О нас
  • Политика конфиденциальности



Контакты для правообладателей: [email protected]