aboutsummaryrefslogtreecommitdiffstats
path: root/googlemock/include/gmock/gmock-actions.h
Commit message (Collapse)AuthorAgeFilesLines
* Googletest exportAbseil Team2020-02-281-3/+33
| | | | | | | | Allow construction of an Action from a callable of zero args Action already allows construction from a callable with the same args as the mocked function, without needing to wrap the callable in Invoke. However, if you don't care about the arguments to the mocked function you need to either accept all of them or wrap your callable in InvokeWithoutArgs. This change makes both of those unnecessary, since it allows you to pass a no-args callable to Action directly. PiperOrigin-RevId: 296117034
* Googletest exportAbseil Team2020-02-071-1/+1
| | | | | | | | | Add missing explicit keyword for gmock_Impl constructor. When switching to using GMOCK_PP in ACTION* macroses `explicit` keyword was missed in gmock_Impl constructor causing ClangTidy warnings in ACTION_P macro. PiperOrigin-RevId: 291159975
* Googletest exportAbseil Team2020-01-161-5/+238
| | | | | | | | | Use GMOCK_PP to create GMOCK_INTERNAL_ACTION macro. Create GMOCK_INTERNAL_ACTION macro that generates ACTION_P* macroses using GMOCK_PP. PiperOrigin-RevId: 289815906
* Googletest exportAbseil Team2020-01-161-0/+16
| | | | | | | | | Use GMOCK_PP to generate args boilerplate. Move common args describing part to separate macroses that uses GMOCK_PP to generate sequences. PiperOrigin-RevId: 289655624
* Googletest exportAbseil Team2020-01-091-0/+37
| | | | | | | | Move part of functionality of Action* class to the base one. Reduce copypaste. Make constructor and conversion operator of Action* class independent of pump. PiperOrigin-RevId: 288907005
* Googletest exportAbseil Team2020-01-091-0/+16
| | | | | | | | Use C++11 variadic templates for Invoke in gmock-generated-actions.h. Replace InvokeArgumentAdl with Invoke that uses C++11 variadic templates. PiperOrigin-RevId: 288449236
* Googletest exportAbseil Team2020-01-021-17/+0
| | | | | | | | | Use C++11 variadic templates for InvokeArgumentAdl in gmock-generated-actions.h. Make InvokeArgumentAdl use variadic templates to generate its overloads instead of using pump.py syntax. PiperOrigin-RevId: 286267615
* Googletest exportAbseil Team2020-01-021-0/+17
| | | | | | | | | Use C++11 variadic templates for InvokeArgumentAdl in gmock-generated-actions.h. Make InvokeArgumentAdl use variadic templates to generate its overloads instead of using pump.py syntax. PiperOrigin-RevId: 286148805
* Googletest exportAbseil Team2019-12-131-0/+40
| | | | | | | | Use C++11 variadic templates for ActionHelper in gmock-generated-actions.h. Make ActionHelper use variadic templates to generate Perform static member function specializations instead of using pump.py syntax. PiperOrigin-RevId: 284988441
* Merge pull request #2583 from ChristophStrehle:masterGennadiy Rozental2019-11-271-1/+2
|\ | | | | | | PiperOrigin-RevId: 282817206
| * Fix compile break for Microsoft Visual Studio 2017 v141Christoph Strehle2019-11-211-1/+2
| | | | | | | | | | | | | | | | This is a workaround, for those who have to compile with v141 build tools, for a bug in msvc that the compiler can't compile the WithArgsAction. see the following link for more details: https://developercommunityapi.westus.cloudapp.azure.com/content/problem/420339/googlemocks-withargs-doesnt-compile-with-permissiv.html
* | Googletest exportAbseil Team2019-11-221-2/+2
|/ | | | | | | | | | | | | Use standard C++11 integer types in gtest-port.h. Remove testing::internal::{Int,Uint}{32,64} in favor of types guaranteed to be in <cstdint> since C++11. Tests for built-in integer type coverage are switched from {Int,Uint}64 to [unsigned] long long, which is guaranteed by C++11 to exist and be at least 64-bit wide. PiperOrigin-RevId: 281565263
* Googletest exportAbseil Team2019-10-311-4/+4
| | | | | | Change variable name to match comment. PiperOrigin-RevId: 277713621
* Merge pull request #2527 from ↵vslashg2019-10-291-0/+4
|\ | | | | | | | | | | PiotrNycz:gmock_prevent_return_ref_to_store_temporaries_2 PiperOrigin-RevId: 277061341
| * Prevent using ReturnRef on reference to temporaryPiotr Nycz2019-10-221-0/+4
| | | | | | | | Fixed issue: 2471
* | Googletest exportAbseil Team2019-10-231-0/+47
|/ | | | | | Add a matcher `testing::ReturnRoundRobin` which, on each call, returns the next element in the sequence, restarting at the beginning once it has reached the end. PiperOrigin-RevId: 276312136
* Merge pull request #2387 from kuzkry:iffShaindel Schwartz2019-09-121-5/+6
|\ | | | | | | PiperOrigin-RevId: 268693457
| * restore mistakenly removed iffs in their explicit formKrystian Kuzniarek2019-08-201-5/+6
| | | | | | | | | | Due to confusion arisen from "iff" standing for "if and only if", this commit uses the latter.
* | Googletest exportHosein Ghahremanzadeh2019-09-121-2/+2
|/ | | | | | | | | Merge 4c9ef099b29d2c840c04643cd9662fd7be712f7b into 565f1b848215b77c3732bca345fe76a0431d8b34 Closes #2403 COPYBARA_INTEGRATE_REVIEW=https://github.com/google/googletest/pull/2403 from IYP-Programer-Yeah:remove-compile-assert-type-equal 4c9ef099b29d2c840c04643cd9662fd7be712f7b PiperOrigin-RevId: 268681883
* remove a custom implementation of std::is_referenceKrystian Kuzniarek2019-08-141-4/+4
|
* fix typosKrystian Kuzniarek2019-07-301-5/+5
|
* Googletest exportAbseil Team2019-05-031-67/+11
| | | | | | Remove special case for protocol buffers. It is no longer needed. PiperOrigin-RevId: 246550795
* Googletest exportAbseil Team2019-04-011-3/+0
| | | | | | | | Remove support for "global" ::string and ::wstring types. This support existed for legacy codebases that existed from before namespaces where a thing. It is no longer necessary. PiperOrigin-RevId: 241335738
* Googletest exportAbseil Team2019-03-211-5/+3
| | | | | | Remove mention of unused type ProtocolMessage. PiperOrigin-RevId: 239242706
* Googletest exportAbseil Team2019-01-171-58/+50
| | | | | | | | | Refactor the `Invoke` and `InvokeWithoutArgs` actions: - Replace pump'd classes and functions with templates. - Make the polymorphic actions be polymorphic functors instead. - Fix Invoke(Callback*) to work with subclasses of the callbacks, instead of trying to diagnose that in gmock_doctor. PiperOrigin-RevId: 229604112
* Googletest exportAbseil Team2019-01-141-29/+5
| | | | | | | Deduplicate testing::ReferenceWrapper with std::reference_wrapper. Minor cleanups in matchers_test. PiperOrigin-RevId: 229022872
* Googletest exportAbseil Team2019-01-021-5/+0
| | | | | | | | Remove the #ifs for old, unsupported and buggy compilers: * old versions of GCC & MSVC * Symbian PiperOrigin-RevId: 227116941
* Googletest exportAbseil Team2018-12-201-56/+20
| | | | | | | | | | | | Use std::function to implement type erasure in Action, wrapping the legacy ActionInterface if necessary. This makes functors / std::function the primary way to implement Action; the existing ActionInterface implementations are handled through ActionAdaptor. The existing actions are not (yet) migrated though; they'll pay the cost of one additional indirection - but that should be negligible. PiperOrigin-RevId: 226126137
* Googletest exportAbseil Team2018-12-201-43/+7
| | | | | | Unifdef c++11-related macros from googletest now that it requires C++11. PiperOrigin-RevId: 225905601
* Googletest exportAbseil Team2018-12-171-46/+40
| | | | | | Replace pump'd code for DoAll with variadic templates. PiperOrigin-RevId: 225584656
* Googletest exportAbseil Team2018-12-031-14/+10
| | | | | | Applied fixes for ClangTidy modernize-use-override and modernize-use-using. PiperOrigin-RevId: 223800219
* Googletest exportmisterg2018-11-201-0/+10
| | | | | | Silence C4100 msvc warning PiperOrigin-RevId: 222242329
* Googletest exportAbseil Team2018-11-201-0/+49
| | | | | | Upgrade WithArgs family of actions to C++11. PiperOrigin-RevId: 221671690
* Googletest exportmisterg2018-10-291-11/+10
| | | | | | Remove linked_ptr and use std::shared_ptr instead PiperOrigin-RevId: 219129336
* Googletest exportAbseil Team2018-10-261-10/+11
| | | | | | Remove linked_ptr and use std::shared_ptr instead PiperOrigin-RevId: 218618184
* Googletest exportmisterg2018-10-261-11/+10
| | | | | | Remove linked_ptr and use std::shared_ptr instead PiperOrigin-RevId: 218571466
* Googletest exportAbseil Team2018-10-181-5/+6
| | | | | | C++11 code cleanup. PiperOrigin-RevId: 217364243
* Unconditionally use std::tuple.Abseil Team2018-10-091-3/+3
| | | | | | Remove all mention of TR1 tuple and our own implementation of tuple. PiperOrigin-RevId: 216395043
* Apply clang-tidy modernize-use-nullptr to googletest.Abseil Team2018-10-051-15/+14
| | | | | | | | | | | Now that googletest has moved to C++11, it should no longer use NULL or 0 for the null pointer. This patch converts all such usages to nullptr using clang-tidy. This prevents LLVM from issuing -Wzero-as-null-pointer-constant warnings. PiperOrigin-RevId: 215814400
* Comments changes, no functionality changesGennadiy Civil2018-08-141-2/+1
|
* Formatting changes for automatic code managementGennadiy Civil2018-07-271-0/+2
|
* mergingGennadiy Civil2018-04-111-17/+73
|
* Revert "gmock actions 2"Gennadiy Civil2018-04-091-73/+17
|
* merging gmock-actions 2Gennadiy Civil2018-04-061-17/+73
|
* More merges, removing old dead codeGennadiy Civil2018-03-131-5/+6
|
* Fix typo in gmock-actions.hHector Dearman2017-06-191-4/+4
| | | | This upstreams a Google-internal change (141765019).
* googlemock: Support C++11 language with pre-C++11 libraryMark Mentovai2015-10-121-4/+4
| | | | | | This guards use of <type_traits> and its features with GTEST_HAS_STD_TYPE_TRAITS_, and std::function with GTEST_HAS_STD_FUNCTION_.
* move googlemock files into googlemock/ subdirBilly Donahue2015-08-251-0/+1205