| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
PiperOrigin-RevId: 518213370
Change-Id: I88d0acc195dadf8d03cd15c8534c721141db14ea
|
|
|
|
|
| |
PiperOrigin-RevId: 515855852
Change-Id: I8016eefd45c36089e189bbd1ebbe9fdabe68255b
|
|
|
|
|
|
|
|
|
|
| |
standard ones
* Standard heterogeneous comparator functors such as `std::equal_to<>` and `std::less<>` [have been available since C++14](https://en.cppreference.com/w/cpp/utility/functional/less_void)
* Now that [C++14 is the minimum supported version of C++ in Googletest](https://github.com/google/oss-policies-info/blob/main/foundational-cxx-support-matrix.md), let's delete these duplications of the standard library
PiperOrigin-RevId: 515743068
Change-Id: I1563a2f94039c3a6688429298555545a922f6d7e
|
|
|
|
|
| |
PiperOrigin-RevId: 504325204
Change-Id: Iaa1d6d0ab1dccaaeef26f9cb109d530835499240
|
|
|
|
|
| |
PiperOrigin-RevId: 499893032
Change-Id: I33304802b7c82ae2d008f3ee89df38866e5f57ba
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Clang warns on this pattern because it looks like the author might
have meant to use the value of the first part of the comma operator,
so it warns that it isn't being used. The cast here signals to Clang
that this behavior is intentional.
This was discovered while updating gmock in Android. Clang's -Wcomma
warning is on by default with either -Wall or -Werror, so users of
gmock with those on in combination with -Werror are unable to build
without this fix.
PiperOrigin-RevId: 495655990
Change-Id: Iaf27e2199669f5b6185a877738234e551b6b6556
|
|
|
|
|
| |
PiperOrigin-RevId: 494786543
Change-Id: I7769558dd2ca046d8957bf352dc04cfb48ff7c3a
|
|
|
|
|
|
|
| |
MatcherDescriberInterface specifies that DescribeTo "should print a verb phrase", but "size ..." is not a verb phrase. Currently, ElementsAre(SizeIs(9)) is described as "has 1 element that size is equal to 9". With this change, it will be described as "has 1 element that has a size that is equal to 9".
PiperOrigin-RevId: 492022324
Change-Id: I4083335f2419462464957521c1e033643b53b763
|
|
|
|
|
|
|
|
| |
trigger via `MOCK_METHOD()` and `EXPECT_THAT()` macros.
Fixes: #4052, #4055
PiperOrigin-RevId: 491647393
Change-Id: I8e2ad838156fa8c7e9dccd1740af797e694992b6
|
|
|
|
|
| |
PiperOrigin-RevId: 469171380
Change-Id: Ic75fc0523924e40e620552d4c04b79dad22a68e0
|
|\
| |
| |
| |
| | |
PiperOrigin-RevId: 464586117
Change-Id: Icda62f13b962f7408bb5698ae2b627391257d152
|
| |
| |
| | |
branch master changed to main on link
|
| |
| |
| |
| |
| | |
PiperOrigin-RevId: 463961734
Change-Id: Ib62e320a745c190955f181c1f4f12e4cd407ef22
|
|/
|
|
|
| |
PiperOrigin-RevId: 458018249
Change-Id: I7df8f75ef5b5a6478e7301f959c221810ff9f0b3
|
|
|
|
|
| |
PiperOrigin-RevId: 446259163
Change-Id: I3ad5f405f44fc233f5cf5a18a274a9104b5c4ab8
|
|
|
|
|
| |
PiperOrigin-RevId: 443715444
Change-Id: I3ffd54b63d2728ae4a668ee7875c8c3c8188087c
|
|
|
|
|
| |
PiperOrigin-RevId: 443462203
Change-Id: I0c43f981663a7531ff5da4d4be01fb3d6762273d
|
|
|
|
|
| |
PiperOrigin-RevId: 439389646
Change-Id: Ie34adcdd2b24378e85962efac53b7bb89ed93803
|
|
|
|
|
|
|
| |
for better error messages.
PiperOrigin-RevId: 427598749
Change-Id: I8c7a5d7b2dde017641534f1c7eed8dd56c33e845
|
|
|
|
|
| |
PiperOrigin-RevId: 422559250
Change-Id: I9f630f2186724950e5e9fbd7093d5264e8bf0a71
|
|\
| |
| |
| |
| | |
PiperOrigin-RevId: 421044680
Change-Id: If585089811f1b67eab6f339125c27174ee5bc290
|
|/
|
|
|
|
| |
They were all removed in #2815, but it looks like this one got added
from a Google export which missed the update. See #2815 for reasons why
removing this is desirable.
|
|
|
|
|
| |
PiperOrigin-RevId: 418497526
Change-Id: Ie53c3c0810c10a32cbcb941e3ca1ee8fb1ddd9f9
|
|\
| |
| |
| | |
PiperOrigin-RevId: 400792845
|
| | |
|
|/
|
|
|
|
|
|
| |
Ensure `.what()` is printed in `ThrowsMessage(...)` to address https://github.com/google/googletest/issues/3582
Closes #3582
PiperOrigin-RevId: 399462851
|
|\
| |
| |
| | |
PiperOrigin-RevId: 398271948
|
| | |
|
| |
| |
| |
| |
| |
| | |
Introduce a new matcher for unescaping Base-64 strings to gmock.
PiperOrigin-RevId: 388471904
|
| | |
|
| |
| |
| |
| |
| |
| | |
Delete GOOGLETEST_CM.* tags from C++ code.
PiperOrigin-RevId: 386268534
|
| |
| |
| |
| |
| |
| | |
Suppress a clang-tidy warning in the MATCHER(name, description) macro.
PiperOrigin-RevId: 383587271
|
| |
| |
| |
| |
| |
| |
| |
| | |
Add `Conditional` wrapper to gtest
This follows an initial proposal for an 'EqIff` matcher. `Conditional` was considered more precise as an EqIff() matcher may suffer from `Iff` not being universally understood.
PiperOrigin-RevId: 383407665
|
| |
| |
| |
| |
| |
| | |
Implement 'Contains(e).Times(n)' matcher modifier which allows to test for arbitrary occurrences including absence with Times(0).
PiperOrigin-RevId: 382210276
|
|\ \
| | |
| | |
| | | |
PiperOrigin-RevId: 379625931
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | | |
Internal change
PiperOrigin-RevId: 362040448
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Update stale links to `gmock_cook_book.md`.
I'm a new googletest user and found these links broken when reading the documentation.
PiperOrigin-RevId: 357786392
|
| | |
| | |
| | |
| | |
| | |
| | | |
Make include guards conform with https://google.github.io/styleguide/cppguide.html#The__define_Guard, attempt #2
PiperOrigin-RevId: 357056902
|
| | |
| | |
| | |
| | |
| | |
| | | |
Revert include guard fix
PiperOrigin-RevId: 356588893
|
| | |
| | |
| | |
| | |
| | |
| | | |
Make include guards conform with https://google.github.io/styleguide/cppguide.html#The__define_Guard
PiperOrigin-RevId: 355882793
|
| |/
|/|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Change Matcher<T> to allow binding an implementation by value directly:
- Drop the requirement of MatcherInterface. Doing manual type erasure avoid
extra layers in many cases.
- Avoid the adaptor for `MatcherInterface<T>` and `MatcherInterface<const T&>` mismatch.
- Use a small object optimization when possible. This makes things like
`_` and `Eq(1)` really cheap and do not require memory allocations.
- Migrate some matchers to the new model to speed them up and to test the new framework. More matchers to come in future changes.
PiperOrigin-RevId: 350580998
|
| |
| |
| |
| |
| |
| | |
Introduce a new `Address` matcher to gmock.
PiperOrigin-RevId: 346344591
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Add a `Pointer` matcher as an analog to `Pointee`.
Similar to `Pointee`, `Pointer` works with either raw or smart pointers and
allows creating a matcher like Pointer(Eq(foo)) for smart pointers.
PiperOrigin-RevId: 346164768
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
GMock: Make Truly explain when it fails
I just wrote a test that had a matcher of the form
Optional(AllOf(
SomeMatcher,
SomeOtherMatcher,
Truly(SomePredicate)))
The predicate failed, the other two matchers succeeded, and I got a hard-to-interpret message saying that the value in the optional "didn't match". Didn't match what?
This change improves situations like that slightly by having Truly explain to its result listener when it fails. When there are multiple Trulys in an AllOf, there will be some ambiguity, but it will at least provide more information than right now.
PiperOrigin-RevId: 341105141
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Remove obsolete comment about non-const references.
They used to be banned by the C++ style guide, but positions shifted, and this comment is no longer up to date.
There's another reference (heh) on lines 816-819 to how gmock is a "general framework", with the possible implication that support for non-const references was weird in some way and only there to be "general", but I left it alone because I don't really feel I understand what it's saying.
PiperOrigin-RevId: 339323428
|
| |
| |
| |
| |
| |
| |
| | |
Fixes build warnings from previous CL
Add CMake to internal presubmit to prevent these
PiperOrigin-RevId: 337325504
|
| |
| |
| |
| |
| | |
Add ::testing::FieldsAre matcher for objects that support get<> and structured bindings.
PiperOrigin-RevId: 337165285
|
|\ \
| | |
| | |
| | | |
PiperOrigin-RevId: 327294137
|