Googletest export

Docs cleanup

PiperOrigin-RevId: 356798444
This commit is contained in:
Abseil Team 2021-02-10 15:22:52 -05:00 committed by Andy Soffer
parent eac6a02cc2
commit 609281088c
3 changed files with 16 additions and 16 deletions

View File

@ -2155,9 +2155,9 @@ NOTE: This feature should only be used for temporary pain-relief. You still have
to fix the disabled tests at a later date. As a reminder, googletest will print to fix the disabled tests at a later date. As a reminder, googletest will print
a banner warning you if a test program contains any disabled tests. a banner warning you if a test program contains any disabled tests.
TIP: You can easily count the number of disabled tests you have using `gsearch` TIP: You can easily count the number of disabled tests you have using
and/or `grep`. This number can be used as a metric for improving your test `grep`. This number can be used as a metric for
quality. improving your test quality.
#### Temporarily Enabling Disabled Tests #### Temporarily Enabling Disabled Tests

View File

@ -8,9 +8,9 @@ object (so it can be used as one), but lets you specify at run time how it will
be used and what it should do (which methods will be called? in which order? how be used and what it should do (which methods will be called? in which order? how
many times? with what arguments? what will they return? etc). many times? with what arguments? what will they return? etc).
**Note:** It is easy to confuse the term *fake objects* with mock objects. Fakes It is easy to confuse the term *fake objects* with mock objects. Fakes and mocks
and mocks actually mean very different things in the Test-Driven Development actually mean very different things in the Test-Driven Development (TDD)
(TDD) community: community:
* **Fake** objects have working implementations, but usually take some * **Fake** objects have working implementations, but usually take some
shortcut (perhaps to make the operations less expensive), which makes them shortcut (perhaps to make the operations less expensive), which makes them
@ -51,9 +51,9 @@ them fast and reliable, using mocks manually in C++ is *hard*:
one. one.
In contrast, Java and Python programmers have some fine mock frameworks (jMock, In contrast, Java and Python programmers have some fine mock frameworks (jMock,
EasyMock, [Mox](http://wtf/mox), etc), which automate the creation of mocks. As EasyMock, etc), which automate the creation of mocks. As a result, mocking is a
a result, mocking is a proven effective technique and widely adopted practice in proven effective technique and widely adopted practice in those communities.
those communities. Having the right tool absolutely makes the difference. Having the right tool absolutely makes the difference.
gMock was built to help C++ programmers. It was inspired by jMock and EasyMock, gMock was built to help C++ programmers. It was inspired by jMock and EasyMock,
but designed with C++'s specifics in mind. It is your friend if any of the but designed with C++'s specifics in mind. It is your friend if any of the
@ -335,7 +335,7 @@ will return 100 the first time, 150 the second time, and then 200 every time.
Some people like to call this style of syntax a Domain-Specific Language (DSL). Some people like to call this style of syntax a Domain-Specific Language (DSL).
**Note:** Why do we use a macro to do this? Well it serves two purposes: first **Note:** Why do we use a macro to do this? Well it serves two purposes: first
it makes expectations easily identifiable (either by `gsearch` or by a human it makes expectations easily identifiable (either by `grep` or by a human
reader), and second it allows gMock to include the source file location of a reader), and second it allows gMock to include the source file location of a
failed expectation in messages, making debugging easier. failed expectation in messages, making debugging easier.